[wp-hackers] Is there a page limit?

Garett Harnish garett at harnish.ca
Thu Mar 2 00:09:54 GMT 2006


I ran into an interesting problem ... that is perhaps unique ... I'm not 
sure.

For one theme, I wanted to restrict the number of posts to 4 and exclude 
an aside category and still page correctly.   As such, I made a new 
WP_query and set it to $wpquery in the index.php of the template ... 
everything worked well except paging.

Normally I'd have 102 pages at 10 pages a post.  At 4, I have 293 pages 
... Anyway, the problem is once I page past 102, I start getting 404 
errors ... of course this is because $wpquery that runs earlier had no 
data ...

Is there any 'good' way to override the default number of posts in a 
theme?  I mean, I have other themes and I don't want to reduce them to 
four posts a page ... just this new one.  If I was increasing the 
number, it work fine ... but since I'm decreasing it ...  I'm figuring 
someone might run into this excluding aside categories as well.

--
Garett


More information about the wp-hackers mailing list