Are you saying I can copy and paste loop 3:
?>
<ul>
<?php
query_posts('category_name=how-tos&showposts=16'); //16 more posts minus those about to be excluded
while (have_posts()) : the_post();
if( $post->ID == $do_not_duplicate ) continue; //exclude the first single ID again
if( in_array($post->ID, $do_not_duplicate_2) ) continue; //exclude the second IDs in array
update_post_caches($posts);
?>
<li id="post-<?php the_ID(); ?>">
<a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title(); ?>"><?php the_title(); ?></a>
</li>
<?php endwhile; ?>
</ul>
<?php
...into sidebar.php and use (is_page('How-To'))
to output the above code only when on the How-To page? If so, that makes sense to me.
The only thing I'm confused about is redeclaring global variables.
This is what my current sidebar.php looks like:
<div id="sidebar">
<ul>
<li>
<?php login_with_ajax(); ?>
</li>
<li>
<h2>Connect</h2>
<center>
<a title="Follow Us On Twitter!" href="http://www.twitter.com" style="margin-right: 10px;" target="_blank"><img alt="Follow Us On Twitter!" src="http://www.image.com/image.png"/></a>
<a title="Add Us On Facebook!" href="http://www.facebook.com" target="_blank"><img alt="Add Us On Facebook!" src="http://www.image.com/image.png"/></a>
</center>
</li>
</ul>
</div>
Can you guide me as to how I'd be able to insert loop 3 in there with the redeclared global variables? I'm assuming I can't just copy and paste loop 3.