• I would appreciate it if someone could help me correct my theme. I’ve tried to correct it but can’t seem to get it right. The code is only from the sidebar.

    <div id="sb_left">

    <br>
    <p><img src="<?php bloginfo('stylesheet_directory'); ?>/Images/Fun.png" align="center" width="200" height="287" alt="Model" /></p>

    <p><img src="<?php bloginfo('stylesheet_directory'); ?>/Images/PB2.png" align="center" vspace="3" width="200" height="25" alt="Publicidade" /></p>

    <p><img src="<?php bloginfo('stylesheet_directory'); ?>/Images/CM2.png" align="center" vspace="3" width="200" height="25" alt="Comentario" /></p>

    <ul><?php bdp_comments(); ?></ul>

    <p><img src="<?php bloginfo('stylesheet_directory'); ?>/Images/PC.png" align="center" vspace="5" width="200" height="25" alt="Publicidade" /></p>

    <p>
    <center>
    <ul><li><?php include (TEMPLATEPATH . '/searchform.php'); ?></li></ul>
    </li></center></p>

    <?php if (function_exists('wp_theme_switcher')) { ?>
    <li><h2><?php _e('Themes'); ?></h2>
    <?php wp_theme_switcher(); ?>
    </li>
    <?php } ?>
    </ul>
    </div>

    <div id="sb_right">

    <br>
    <ul>
    <p><img src="<?php bloginfo('stylesheet_directory'); ?>/Images/Posts2.jpg" align="center" width="190" height="85" alt="Model" /></p>

    <li><ul><?php bdp_posts(); ?></ul>

    <p><img src="<?php bloginfo('stylesheet_directory'); ?>/Images/girls.jpg" align="center" width="190" height="85" alt="Model" /></p>

    <li>
    <ul>
    <?php list_cats(0, '', 'name', 'asc', '', 1, 0, 1, 1, 1, 1, 0,'','','','','') ?>
    </ul>
    </li>

    <?php if (function_exists('wp_theme_switcher')) { ?>
    <li><h2><?php _e('Themes'); ?></h2>
    <?php wp_theme_switcher(); ?>
    </li>
    <?php } ?>

    </ul>

    <ul>

    <p><img src="<?php bloginfo('stylesheet_directory'); ?>/Images/scream2.jpg" align="center" width="190" height="85" alt="Model" /></p>

    <li>
    <?php jal_get_shoutbox(); ?>
    </li>

    </ul>

    <ul>

    <p><img src="<?php bloginfo('stylesheet_directory'); ?>/Images/Links.jpg" align="center" width="190" height="85" alt="Links" /></p>

    <?php get_links_list(); ?>
    <li>
    <h2>

    <?php _e('Meta'); ?>
    </h2>
    <ul>
    <?php wp_register(); ?>
    <li>
    <?php wp_loginout(); ?>
    </li>

    <li><a href="http://www.site.com">Name</a></li&gt;
    <li><a href="http://wordpress.org/&quot; title="<?php _e('Powered by WordPress, state-of-the-art semantic personal publishing platform.'); ?>">WordPress</a></li>
    <?php wp_meta(); ?>
    </ul>

    </li>

    <p><img src="<?php bloginfo('stylesheet_directory'); ?>/Images/AQ.jpg" align="center" width="190" height="85" alt="Links" /></p>

    <li>
    <ul>
    <?php wp_get_archives('type=monthly'); ?>

    </ul>

    </li>

    </ul>
    </div>

    I hate to paste all the code like this but I’ve run out off options. If anyone could help me with this problem I would really appreciate it.

Viewing 7 replies - 1 through 7 (of 7 total)
  • Please use pastebin for the code and let us have the link:
    http://pastebin.com

    You haven’t said what is wrong? Just that it is wrong..

    Thread Starter Emperor

    (@emperor)

    Thanks for the quick reply I was still trying to display the code on the thread correctly.
    The basic problem is that I had to change the code to add a few images to de sidebar. Because I’m not that familiarised with WP Templates I just did some searching and added the code the way I saw on various sites I visited. The URL is http://www.amar-ela.com

    Thread Starter Emperor

    (@emperor)

    I link to the code is: http://pastebin.com/667706

    Thread Starter Emperor

    (@emperor)

    I have searched the web for an answer to my problem but haven’t been able to find solution. The best way I can describe what’s wrong with the code is that the
    <ul> and </ul>
    tags are missing from verious places in the code. I would give a more in depth explanation but I’m afraid this is the best I can do.

    you have a LOT of <ul> and </ul> that is misplaced, and some <li> and </li> and <p> tags too.

    http://validator.w3.org/check?uri=http%3A%2F%2Fwww.amar-ela.com%2F&charset=%28detect+automatically%29&doctype=Inline&ss=1 – this will help you. check out the errors there and go in to fix them.

    Thread Starter Emperor

    (@emperor)

    Thanks for your help ladydelaluna. I did manage to fix 9 errors but am having trouble with the rest. The main problem is that I moved some code around and now don’t know how to add the tags correctly. An example would be in the beginning of the sidebar the </ul> tag is missing but every time I try adding it the sidebar becomes messed up.

    think of <ul> as the beginning of a “section” and </ul> as the end of a section. the <li> and </li> are to separate the different things within that section of the sidebar…

    so you might have:

    <ul>
    <li>something here - say, an image</li>
    <li>your list of links</li>
    </ul>

    and then for the next section

    <ul>
    <li>something else here - maybe your list of pages</li>
    </ul>

    does that make sense?

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

The topic ‘Template coding gone wrong’ is closed to new replies.