ThemeShaper Forums » Thematic


function syntax error?

(3 posts)
  • Started 12 years ago by PitaMaria
  • Latest reply from PitaMaria
  • This topic is resolved
  1. PitaMaria

    I'm getting validation errors around a widget I added via a new function. I forgot where I got the function code but I'm including it below. I think it's kicking out a
    <li> and a <div> that aren't closing properly. For an example of the elements in action go to Any help diagnosing the problem would be greatly appreciated.

    function my_header_widgets() {
    if ( function_exists('dynamic_sidebar') && is_sidebar_active('header-aside') ) {
        echo '<div id="header-aside" class="aside">'. "\n" . '<ul class="xoxo">' . "\n";
        echo '' . "\n" . '</div><!-- #header-aside .aside -->'. "\n";
    add_action('thematic_header', 'my_header_widgets', 8);
    Posted 12 years ago #
  2. Looks like you are not closing your unordered list. Change the 5th line to:

    echo '' . "\n" . '</ul></div><!-- #header-aside .aside -->'. "\n";


    Posted 12 years ago #
  3. PitaMaria

    @diverge: Thanks!

    Posted 11 years ago #

RSS feed for this topic

Topic Closed

This topic has been closed to new replies.