[SOLVED] Add footer item only to landing page.
I want to add a video to the bottom of only the Front Page (I have a static landing page). I can't see how to do that.
I did find this thread... http://forum.bytesforall.com/showthr...ter+front+page and thought I may be able to use it, but wasn't able to figure out how to use that with an embedded video from youtube. Any ideas? Velma |
Try this add the code to ATO->Style & edit CENTER COLUMN->Content BELOW the LOOP and surround it with
<?php if (is_front_page() ) { ...your code goes here... } ?> |
That's what I tried. This is the error that shows up on the Front Page after I save the code.
Parse error: syntax error, unexpected '<' in /home/pdrags/public_html/strategicsense.ca/wp-content/themes/atahualpa/functions.php(478) : eval()'d code on line 1 It's youtube code I was putting in there. |
please cut and paste, exactly what you have in 'Below the LOOP', in a reply and befory you paste it, hit the little 'html' button so it will be surrounded by [ HTML ] [ /HTML ] so I can take a look
|
This is what I was putting in there. The first section is for the video. The rest is what's standard in there with the Theme.
HTML Code:
<?php if (is_front_page() ) { <object width="480" height="385"><param name="movie" value="http://www.youtube.com/v/fgZwnDlM_ks&hl=en_US&fs=1&rel=0&color1=0xe1600f&color2=0xfebd01"></param><param name="allowFullScreen" value="true"></param><param name="allowscriptaccess" value="always"></param><embed src="http://www.youtube.com/v/fgZwnDlM_ks&hl=en_US&fs=1&rel=0&color1=0xe1600f&color2=0xfebd01" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="480" height="385"></embed></object> } ?> |
Change the first part to this
HTML Code:
<?php if (is_front_page() ) { ?> |
OK! So what if I wanted to put something different on another page...say like a testimonial or something. How do I identify the other page? By the page number?
How would I phrase the if statement? |
check out http://codex.wordpress.org/Conditional_Tags to see all teh conditional tags and their structure
|
Perfect. Thanks.
I'm glad I found this place, and donated (and will add more later). I've learned a TON here already...both from asking and just reading. |
All times are GMT -6. The time now is 08:51 PM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.