WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] Help! Parse Error (6 posts)

  1. JSDavis82
    Member
    Posted 7 years ago #

    In attempting to implement a dynamic sidebar on my blog so I can use the widget plugin, I get a strange parse error on line 90. Line 90 isn't even a line near the code to make the sidebar dynamic, but when I take that code out, the site works again. Can anyone help please?

  2. chaaban
    Member
    Posted 7 years ago #

    nop we cant :)

    sorry

    good luck for you when at least u past the code ;)

  3. Chris_K
    Member
    Posted 7 years ago #

    If you'd like to toss your code in a pastebin (one is http://wordpress.pastebin.ca/) and then give us a link, someone could take a link.

    A link to the site in question may be helpful too.

  4. JSDavis82
    Member
    Posted 7 years ago #

    so sorry, new to wordpress. here's the code.

    function.php also contains the code:

    <?php
    if ( function_exists('register_sidebar') )
    register_sidebar();
    ?>

    thanks for the help!

  5. Samuel Wood (Otto)
    Tech Ninja
    Posted 7 years ago #

    Between line 83 and 84, just before the </div>, add this:
    <?php endif; ?>

    The reason is this bit of code:
    <?php if ( !function_exists('dynamic_sidebar')
    || !dynamic_sidebar() ) : ?>

    That is basically saying to display the widget sidebar if it's enabled, but if it's not, display the following default sidebar code instead. You need the endif to tell it where the end of the default sidebar code is.

  6. JSDavis82
    Member
    Posted 7 years ago #

    thanks otto, that worked. check out the blog

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags