Wordpress Themes - WP Forum at BFA

Wordpress Themes - WP Forum at BFA (http://forum.bytesforall.com/index.php)
-   Header configuration & styling (http://forum.bytesforall.com/forumdisplay.php?f=15)
-   -   Putting Flash between %logo and %menu (http://forum.bytesforall.com/showthread.php?t=1206)

eyup Apr 10, 2009 08:34 AM

Putting Flash between %logo and %menu
 
Hi Flynn,

I've managed to put a Flash banner below the logo and menu area -

http://conraddavies.com/hif/

but would like to put it between these two elements - so the logo is above and the menu below.
Is that possible?

Regards

(ps dosh inbound)

Flynn Apr 11, 2009 05:22 AM

At the moment you'd have to edit functions/bfa_header_config.php for this

Change
PHP Code:

    $logo_area .= '</tr></table>';    
    
// END of Logo Area 


to

PHP Code:

    $logo_area .= '</tr></table>';    
    
// END of Logo Area 
}

$logo_area .='
YOUR CODE HERE
'


to append your code to the logo area

eyup Apr 11, 2009 07:10 AM

Hi Flynn,

Thanks for the quick response.

I'm getting this:

Parse error: syntax error, unexpected T_STRING in /home/conraddavies/BE9N04NB/htdocs/hif/wp-content/themes/atahualpa332/functions/bfa_header_config.php on line 191

(I presume - $logo_are .=' should also be $logo_area .=' ) - 'area' not 'are'?




PHP Code:

        // END of Search box 

    
$logo_area .= '</tr></table>';    
    
// END of Logo Area 
}

$logo_area .='
<script src="http://conraddavies.com/Scripts/AC_RunActiveContent.js" type="text/javascript"></script>
<script type="text/javascript">
AC_FL_RunContent( '
codebase','http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,28,0','width','960','height','180','src','/hif/wp-content/themes/atahualpa332/images/header/hif','quality','high','pluginspage','http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash','movie','/hif/wp-content/themes/atahualpa332/images/header/hif' ); //end AC code
</script><noscript><object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,28,0" width="960" height="180">
          <param name="movie" value="/hif/wp-content/themes/atahualpa332/images/header/hif.swf" />
          <param name="quality" value="high" />
          <param name="wmode" value="opaque" />
          <embed src="/hif/wp-content/themes/atahualpa332/images/header/hif.swf" quality="high" wmode="opaque" pluginspage="http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash" type="application/x-shockwave-flash" width="960" height="180"></embed>
        </object></noscript>
'; 

if (strpos($header_items,'%image')!==false) {
    // Header Image 


Flynn Apr 11, 2009 09:45 PM

Yes, that should have been logo_area, sorry, and fixed it in the post above

Also, replace all single quotes in your code (not in the complete code, just in your code) with double quotes

eyup Apr 12, 2009 05:31 AM

It worked! Cheers Flynn.

One thing though - in Firefox and Safari there is a gap above the menu and below the Flash. In IE7 it's OK. Any ideas how to get rid?

http://www.s-on.co.uk/designerstalk/gap.jpg

eyup Apr 12, 2009 08:54 AM

Ah haa - sussed it!

I put the flash code in a div with the specified height!

So for anybody else wanting to do this here's the final code:

PHP Code:

        // END of Search box 

    
$logo_area .= '</tr></table>';    
    
// END of Logo Area 
}

$logo_area .='
<div style="height: 180px;"><script src="http://conraddavies.com/Scripts/AC_RunActiveContent.js" type="text/javascript"></script>
<script type="text/javascript">
AC_FL_RunContent( "codebase","http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,28,0","width","960","height","180","src","/hif/wp-content/themes/atahualpa332/images/header/hif","quality","high","pluginspage","http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash","movie","/hif/wp-content/themes/atahualpa332/images/header/hif" ); //end AC code
</script><noscript><object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,28,0" width="960" height="180">
          <param name="movie" value="/hif/wp-content/themes/atahualpa332/images/header/hif.swf" />
          <param name="quality" value="high" />
          <embed src="/hif/wp-content/themes/atahualpa332/images/header/hif.swf" quality="high" pluginspage="http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash" type="application/x-shockwave-flash" width="960" height="180"></embed>
</object></noscript></div>
'
;
if (
strpos($header_items,'%image')!==false) {
    
// Header Image 

Of course don't forget to upload AC_RunActiveContent.js (in mine it's in a folder called 'Scripts' in the root directory).

deltahouse Sep 18, 2009 02:30 PM

Hi all
my code was:

$logo_area .='
<div style="height: 100px;"><script src="http://www.mysite/wordpress/scripts/AC_RunActiveContent.js" type="text/javascript"></script>
<script type="text/javascript">
AC_FL_RunContent( "codebase","http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,28,0","width","850","heigh t","100","src","/wordpress/wp-content/themes/atahualpa342/images/testata.swf","quality","high","pluginspage","http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash","movi e","/wordpress/wp-content/themes/atahualpa342/images/testata.swf" ); //end AC code
</script><noscript><object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,28,0" width="850" height="100">
<param name="movie" value="http://mysite.com/wordpress/wp-content/themes/atahualpa342/images/testata.swf" />
<param name="quality" value="high" />
<embed src="http://mysite.com/wordpress/wp-content/themes/atahualpa342/images/testata.swf" quality="high" pluginspage="http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash" type="application/x-shockwave-flash" width="850" height="100"></embed>
</object></noscript></div>
';


...but i see only a blank space in the right position. The .js file has benn uploaded of course.
Where is the error?
Thank you....

eyup Sep 18, 2009 02:55 PM

forget that

get the Dynamic Headers plugin and:

With version 3.4.2 - instead of messing with the php files you can insert Dynamic Headers by simply pasting
<?php show_media_header(); ?> in the option pages, simply go to:

Style & edit HEADER AREA > Configure Header Area

Here's an example:

%logo %image %pages %bar1 <?php show_media_header(); ?> %bar2

Also with WP 2.8 it now remembers which header for which page - unlike before when it reset to the default. Wey hey.

deltahouse Sep 19, 2009 02:16 AM

Perfect! It works. :)
Thank you very much...

gasserol May 27, 2010 04:24 AM

This is a simple and working solution. Tried it with WP version 2.9.2 and ATA 3.4.9


All times are GMT -6. The time now is 07:05 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.