#1 (permalink)  
Old 10-11-2007, 11:35 PM
gkideas gkideas is offline
Junior Member
 
Join Date: Aug 2007
Posts: 13
Default Fun and games with the sidebar

Hi all,

I changed the WP template to the 2 column one by Dewald and have been messing around with the order of things in the sidebar. What I wanted to do was move the Site Tags below the Catagories and Recent Entries. One would think it would be a simple cut and paste. However, now I've ended up with 3 Site Tag sections!

Here's the site:

Best Organic Skincare

and here's the code from the sidebar.php file: (after the Recommended tag)

<h2>Search This Site:</h2>
<div class="menublock">
<form id="searchform" method="get" action="<?php echo $_SERVER['PHP_SELF']; ?>">
<input class="searchfield" type="text" name="s" id="s" value="" title="Enter keyword to search" />
<input class="submit" type="submit" value="search" title="Click to search archives" />
</form>
</div>

<h2><?php _e('Categories:'); ?></h2>
<ul class="menublock">
<li><?php list_cats(0, '', 'name', 'asc', '', 1, 0, 0, 1, 1, 1, 0,'','','','','',TRUE) ?></li>
</ul>

<h2>Recent Entries:</h2>
<ul class="menublock">
<?php $latest = new WP_Query('showposts=5');
while ($latest->have_posts()) : $latest->the_post(); ?>
<li><a href="<?php the_permalink(); ?>" id="post-<?php the_ID(); ?>"><?php the_title(); ?></a></li>
</ul>

<h2>Site Tags:</h2>
<ul class="menublock">
<font size="2"><?php UTW_ShowWeightedTagSetAlphabetical("coloredsizedta gcloud","","25") ?></font>
</ul>


<?php endwhile; ?>

<?php if (function_exists('get_recent_comments')) { ?>
<li><h2><?php _e('Recent Comments:'); ?></h2>
<ul>
<?php get_recent_comments(); ?>

</ul>
</li>
<?php } ?>

<?php sem_subscribe_me(); ?>

<h2>Favorite Links:</h2>
<ul class="menublock">
<li><?php get_linksbyname('', '', '<br />', '', TRUE, 'name', FALSE, TRUE); ?></li>
</ul>

<?php if (function_exists('translate')) { ?>
<h2>Translate Site:</h2>
<ul class="menublock">
<li><?php translate(1); ?></li>
</ul>
<?php } ?>


<h2>Meta:</h2>
<ul class="menublock">
<?php wp_register(); ?>
<li><?php wp_loginout(); ?></li>
<?php wp_meta(); ?>
</ul>


</div>


</div>

Any ideas what I did wrong?
Thanks for your help.

GiGi
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 10-12-2007, 12:46 AM
WestWing888 WestWing888 is offline
Member
 
Join Date: Feb 2007
Posts: 85
Default

You've got your site tag code stuck in a loop.

Move this; <?php endwhile; ?> ABOVE this; <h2>Site Tags:</h2>

So it ends up looking like this;

<h2>Recent Entries:</h2>
<ul class="menublock">
<?php $latest = new WP_Query('showposts=5');
while ($latest->have_posts()) : $latest->the_post(); ?>
<li><a href="<?php the_permalink(); ?>" id="post-<?php the_ID(); ?>"><?php the_title(); ?></a></li>
</ul>

<?php endwhile; ?>

<h2>Site Tags:</h2>
<ul class="menublock">
<font size="2"><?php UTW_ShowWeightedTagSetAlphabetical("coloredsizedta gcloud","","25") ?></font>
</ul>

Mike
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 10-12-2007, 04:08 PM
gkideas gkideas is offline
Junior Member
 
Join Date: Aug 2007
Posts: 13
Default

That worked!

Thanks so much! Saved me a lot of time.

GiGi
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


All times are GMT. The time now is 02:18 AM.


vBulletin style developed by Transverse Styles

Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.0.0