hey there,
i added a css horizontal drop down menu at the end of header.php. now i wanted to use the loop, which i only have a basic understanding of, to automatically add the 9 latest posts to the 2 categories each i have displayed in the menu. ok, don't think i described this very clearly. here's the code i have in the menu:
-
<li class="bg"><?php _e('the idea'); ?>
<li class="bg"><?php _e('about me'); ?>
<li class="bg"><?php _e('travel map'); ?>
<li class="bg"><?php _e('equipment'); ?>
<li class="bg"><?php _e('faq'); ?>
<li class="bg"><?php _e('support me!'); ?>
<li class="bg"><?php _e('beach bum'); ?>
<li class="bg"><?php _e('contact'); ?>
<li class="bg"><?php _e('credits'); ?>
<li class="bg"><?php _e('travel tips'); ?>
-
<?php query_posts('category_name=travelogues&showposts=9'); ?>
<?php while (have_posts()) : the_post(); ?>
<li class="bg">"><?php the_title(); ?>
<?php endwhile; ?>
<li class="bg"><?php _e('archive'); ?>
-
<?php query_posts('category_name=gallery&showposts=9'); ?>
<?php while (have_posts()) : the_post(); ?>
<li class="bg">"><?php the_title(); ?>
<?php endwhile; ?>
<li class="bg"><?php _e('archive'); ?>
<li class="nomargin"><?php _e('community'); ?>
-
<li class="bg"><?php _e('travel-junkie guides'); ?>
<li class="bg"><?php _e('forum'); ?>
the thing is that it worked perfectly for the menu. it displayed everything correctly. it just totally mangled up my blog. when i still had it uploaded like this it didn't matter what link i clicked, it only ever displayed the same post. here's a link to the site without the loop part in the menu: http://www.travel-junkie.com/travelogues/
i really appreciate any help. don't know what else to do and a solution to this would save me so much time.
cheers,
bo