WordPress.org

Ready to get started?Download WordPress

Forums

Iframe inside a conditional tag in sidebar (5 posts)

  1. DannoUK
    Member
    Posted 8 years ago #

    I want to include an Iframe inside a conditional tag in the sidebar, but as I have very little coding exeperience I have no clue.

    On my page named Music I wish to include an itunes Iframe. In the sidebar I have added this:

    if (is_page('Music')) {

    }
    else {

    }

    ...at the top. When I add the iframe information shown below, I get all kinds of parse errors and know this is because of my coding stupidity. Please help!

    <iframe src="http://pf.tradedoubler.com/pf/pf2?a=863157&cuid=97853&tid=5045&oe=ISO-8859-1" width="200" height="500" frameborder="0" border="0" marginwidth="0" marginheight="0" scrolling="yes"></iframe>

    ..Thanks!

  2. petit
    Member
    Posted 8 years ago #

    Is "Music" a Page page or is it a category?

  3. jabecker
    Member
    Posted 8 years ago #

    Is "music" a static page? You could build a template for that page that includes the iframe. That way you wouldn't need the conditional statement.

  4. DannoUK
    Member
    Posted 8 years ago #

    Music is a static page... my understanding hasnt got as far as individual templates yet hehe! If thats the best way of doing it I should take a look at that!! Would this be the best solution?

  5. petit
    Member
    Posted 8 years ago #

    Maybe a link to your site would help people to analyze what your aim is a bit better. And maybe you *should* dive into templates after all. I think a page like this should be part of your theme.

Topic Closed

This topic has been closed to new replies.

About this Topic