query_posts loops page content
-
I am having an issue with showing query_post lists and calling the page content (using an custom template). Basically, the lists show up but not the page content.
The query_posts get called first:
<ul id="events"> <?php query_posts('cat=3&showposts=2'); ?> <?php while (have_posts()) : the_post(); if( $post->ID == $do_not_duplicate ) continue; ?> <li class="news_post_1" id="post-<?php the_ID(); ?>"> <h2><?php if (strlen($post->post_title) > 25) { echo substr(the_title($before = '', $after = '', FALSE), 0, 25) . '...';} else {the_title();} ?></h2> <?php the_time('l j F, Y') ?> | <a href="<?php echo get_permalink(); ?>">More...</a> </li> <?php endwhile; ?> </ul> <ul id="news"> <?php query_posts('cat=4&showposts=2'); ?> <?php while (have_posts()) : the_post(); if( $post->ID == $do_not_duplicate ) continue; ?> <li class="news_post_1" id="post-<?php the_ID(); ?>"> <h2><?php if (strlen($post->post_title) > 25) { echo substr(the_title($before = '', $after = '', FALSE), 0, 25) . '...';} else {the_title();} ?></h2> <?php the_time('l j F, Y') ?> | <a href="<?php echo get_permalink(); ?>">More...</a> </li> <?php endwhile; ?> </ul>
Then a few divs later I need the page content to show up but have tried a number of things and all I get is a blank page.
Any help would be great
Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
- The topic ‘query_posts loops page content’ is closed to new replies.