$Paged Won't Set On Index When Static Page Is Set
|Reported by:||tehfab1||Owned by:|
Hey Wordpress Masters :),
I've spent the better part of four hours trying to figure what the heck was going on with a new template I've been developing for Wordpress 3.0.
After some rather extensive testing I figured out that when you have a custom loop on a wordpress page (e.g. query_posts()) and that page is set as the static front page of the blog, the pagination seems to break completely.
As an example I have two images here. I went to a more standard wordpress theme since my theme is still incomplete. Basically what I did was set a page as the static front page of the site and then added the following code to the page.php file in the template:
On any other page of the site, if I visited that page it would output a number. Like:
blog.com/pagename/page/2 would die with "int(2)".
But on the index, a URL like
blog.com/page/2 produced a var_dump of "string(0) """ like so:
This odd behavior ONLY happens on the index of the site, and ONLY when a static page is set. Any other page on the site seems to paginate perfectly fine, regardless of if there is a wordpress loop on the page or not.
I even tried turning off permalinks and reverting backed to index.php?paged=2 . Still no luck if I have a static page set.
Any help would be greatly appreciated. Not sure if there is a proper way to fix this, but I'm fairly certain at this point that this is a wordpress 3.0 issue.
I'm running 3.0-RC2-15182 on Dreamhost Shared Hosting.
PHP5 (don't know the version number).
Thanks in advanced for any insight you can provide :).
Change History (12)
- Cc dd32 aaroncampbell added
- Keywords paged pagination $paged get_query_var('paged') removed
comment:10 follow-up: ↓ 11 nacin — 4 years ago
- Milestone 3.0 deleted
- Resolution set to worksforme
- Status changed from new to closed