Control the number of posts displayed on the main page?
-
I’d like to set the number of posts on the index to something different than the default (i.e. what I set under Options > Reading).
I’ve tried out both the code given here
(<?php static $ctr = 0; if ($ctr == "X")
)
and here
(if ($_SERVER[REQUEST_URI] == "/") { $posts = get_posts('numberposts=X');
)
but just keep getting error messages.Apparently I don’t know enough about PHP to implement those instructions (both lack
<?php
markers somewhere, I think?), so I would be very grateful if someone could post the exact code that is required to limit the number of entries.Thanks a lot!
Viewing 4 replies - 1 through 4 (of 4 total)
Viewing 4 replies - 1 through 4 (of 4 total)
- The topic ‘Control the number of posts displayed on the main page?’ is closed to new replies.