[wp-hackers] Changing the Default Number of Posts in a Theme [was: Is there a page limit?]

Garett Harnish garett at harnish.ca
Thu Mar 2 00:19:56 GMT 2006


Apologies about the subject.   I started composing the e-mail before I 
figured out why I couldn't go past page 102 and I forgot to change it 
before I sent it.

--
Garett

Garett Harnish wrote:
> 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
> _______________________________________________
> wp-hackers mailing list
> wp-hackers at lists.automattic.com
> http://lists.automattic.com/mailman/listinfo/wp-hackers
> 



More information about the wp-hackers mailing list