• Resolved goldmember

    (@goldmember)


    the validator is telling me that there are a bunch of errors related to how the top nav bar UL is designs in the theme that I have applied to this site: https://willowbilliards.com/wordpress/?page_id=14

    when i look in the header.php file, i find that the code that generates this list is

    <ul id="page-list">
    
    <?php wp_list_pages('title_li='); ?>
    
    </ul><!-- /page-list -->

    so how do i edit this code to clean up what gets spit out in the source code (below)???

    <ul id="page-list">
    
    <li><li class="page_item page-item-27"><a href="https://willowbilliards.com/wordpress" title="HOMEPAGE">HOMEPAGE</a></li>
    <li class="page_item page-item-2"><a href="https://willowbilliards.com/wordpress/?page_id=2" title="ABOUT US">ABOUT US</a></li>
    <li class="page_item page-item-14 current_page_item"><a href="https://willowbilliards.com/wordpress/?page_id=14" title="CONTACT US">CONTACT US</a></li>
    <li class="page_item page-item-12"><a href="https://willowbilliards.com/wordpress/?page_id=12" title="DIRECTIONS">DIRECTIONS</a></li>
    <li class="page_item page-item-10"><a href="https://willowbilliards.com/wordpress/?page_id=10" title="EVENTS">EVENTS</a></li>
    <li class="page_item page-item-4"><a href="https://willowbilliards.com/wordpress/?page_id=4" title="LEAGUES">LEAGUES</a></li>
    </li>
    
    </ul><!-- /page-list -->
Viewing 6 replies - 1 through 6 (of 6 total)
  • as far as i interprete the validator output, it refers to this code in sidebar.php:
    </li> <div class="sidebar-bottom"></div>

    and the solution could be to move this bit <div class="sidebar-bottom"></div> to after the </ul>

    Thread Starter goldmember

    (@goldmember)

    i guess i cleaned up the top nav bar issues which originally appeared in the validator so now its down to the sidebar issues, which you saw.

    so i tried your recommendation but the validator errors were not reduced.

    below is the code from the top portion of my sidebar.php file that is generating these sections with the errors. any idea how to adjust???

    <div class="sidebar">
    <div id="sideb">
        <ul>
          <div class="sidebar-top"></div>
          <div class="sidebar-body">
    <?php
    		if ( !function_exists('dynamic_sidebar') || !dynamic_sidebar() ) :
    		?>
    <?php endif; ?>
        </ul>
          <div class="sidebar-bottom"></div>
    </div>
    
    <!-- start 125x125 px ads -->

    it looks as if the <ul> could be better after the divs, like so:

    <div id="sideb">
    
          <div class="sidebar-top"></div>
          <div class="sidebar-body"><ul>
    Thread Starter goldmember

    (@goldmember)

    thanks. that did seem to cut down on the validator errors.

    if you dont mind, how do i fix the problems with the </body> and </html> that the validator is complaining about?

    this is the code from my footer:

    </div><!-- /inner-body -->
    
    <div id="footer">
    
    Designed with love by <a href="#">SBM</a>.
    
    </div><!-- /footer -->
    
    </body>
    </html>

    seems normal enough to me…right????

    the body and html errors are follow-ups from the one missing end div.

    if you can find that, the page should validate.

    Thread Starter goldmember

    (@goldmember)

    thank you! i couldnt figure it out, but i put in an extra closing div
    </div><!-- /myster-div--> in the footer.php and now everything passes.
    thanks.

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘php list class issues’ is closed to new replies.