Whats the problem with this code?
-
My code:
<?php // turn off WordPress themes and include the WordPress core: define('WP_USE_THEMES', false); require($_SERVER['DOCUMENT_ROOT'] . '/blog/wp-blog-header.php'); ?> <?php global $query_string; query_posts($query_string . "&order=DESC"); while (have_posts()) : the_post(); ?> <div style="width:500px;margin-bottom:20px;"> <div style="width:500px;padding:2px;background:#336666;color:#FFF;font-size:14px;font-weight:800;"> <?php the_title(); ?></div> <div style="width:500px;border-bottom:1px dashed #666;padding:2px;"></div> <div style="width:500px;padding:4px;text-align:justify;"><?php the_excerpt(); ?></div> <div style="width:500px;border-bottom:1px dashed #666;padding:2px;"></div> <div style="width:400px;"> <div style="float:left;">Por <b><?php the_author(); ?></b> em <?php the_date('d/m/Y'); ?></div> </div> </div> <br /><br /> <?php endwhile; ?> <?php posts_nav_link(' | ', 'Próxima Página', 'Página Anterior'); ?>
I have 3 posts and I want to show only 2 with pagination…
But the pagination doesnt appears… and just first post show the date, the next doesnt show…How can I fix it?
Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
- The topic ‘Whats the problem with this code?’ is closed to new replies.