• I’ve been trying to get the sliding door technique on WP 3.4.

    After some research, I found that I can accomplish this by adding to the wp_nav_menu function. My code looks like this:

    <?php wp_nav_menu( array( ‘link_before’ => ‘<span>’, ‘link_after’ => ‘</span>’, 'sort_column' => 'menu_order',
    'menu_class' => 'nav', 'container_id' => 'header', 'theme_location' => 'primary-menu' ) ); ?>

    When I try to load my site, i get the following error:

    Parse error: syntax error, unexpected ‘>’ in …/wp-content/themes/test theme/header.php on line 30

    I already have my nav menu set up, but I wanted to add customized background images to it through CSS…

    Could someone please point me in the right direction?

Viewing 4 replies - 1 through 4 (of 4 total)
  • Parse error: syntax error, unexpected $end in /home/aranea/public_html/bettingtradition.com/wp-content/themes/sliding-door/functions.php on line 460

    same problem. after trying to define a header image

    Open up your header.php file and go to line 30 and look for the nearest opening and closing <?php'?>` tags and make sure they are closed before an html section and open for a php section.

    Usually this happens something like this:

    <?php some_function( $foo = $foo ) {
          echo $foo
    }
    <div id="bar">

    There should be a ?> closing php tag after the left curly bracket that will throw the same error your reporting.

    Thread Starter Flickie

    (@flickie)

    Pastebin
    There’s a link to my header.php

    Line 30 is the wp_nav_menu function. I’m not exactly sure what you mean by that.

    Should I put the ?> tag right before the ‘<span>’ tags and reopen <?php right after them?

    I have very little experience with php, so I’m not that great with the syntax yet…

    Thread Starter Flickie

    (@flickie)

    I figured it out. Putting double quotes around the <span> tags seemed to do the trick.

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Parse error on Sliding Door’ is closed to new replies.