Paged Navigation doesn’t Work
-
Hi guys!!
My page navigation isn’t working since I changed the Blog URL. the core wordpress is http://www.igmosi.com/blog but it’s showed in http://www.igmosi.com. In the blog section, the links previous and next post doesnt work correctly, the page 1 is always showed.
I reseted the .htaccess file, I have permalinks (blog/%postname%), … mi .htaccess is:
# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule># END WordPress
I have no idea…Where is the problem??
http://www.igmosi.com/blogThank you!!
-nacho
-
The problem is code php tha tI changed to style differently the first post. I copied the code from here, but I cant see where is the porblem.
thnaks.
-nachothe problem with that code is that it does not take pagination (the
pagedparameter for query_posts()) in consideration.
and using theoffsetparameter does general not work well with pagination.checking this article might help:
http://stylizedweb.com/2008/08/13/query_posts-pagination-problem/to style the first post different, you could use a different method that utilizes a counter variable to distinguish the first post (and only on front page);
schematic:
<?php $counter = 1; ?> <?php if (have_posts()) : while (have_posts()) : the_post(); ?> <?php if(($counter == '1')&&!is_paged()) { ?> <?php // show the first post different ?> <?php } else { ?> <?php // show all other posts in their own way ?> <?php } ; ?> <?php $counter++; ?> <?php endwhile; else: ?> <?php endif; ?>Thank you very much!!
It fixed it!!!!
-nacho
The topic ‘Paged Navigation doesn’t Work’ is closed to new replies.