Blog List – Limit
-
Hi,
We have posts to show in the news page under categories..
We created a page “News & events” in “News category 1” & created many posts in “News category 1″ as well..
Now the coding of the news template is below:This displaying only 15 posts out of 20..
In Admin Settings> Reading > Blog pages show at most – set as 16
It is showing only 15… My Question is two.1. My News and Events page id is 812… My one of the post id among 20 posts is 812. So when i write the query as get_posts with post_type => ‘post’ , it gets the page also.. So the page name & created date also displaying as one of the post in the news page. So total 15 posts(out of 20) are showing & 1 is page name showing..
For this reason only we wrote the if coding as => if($page_id != $post_id):
We need to get posts only (except page). what to do?
2. Second question is I have mentioned the ‘numberposts’ => -1” in the query.. But it is getting the posts which was set the count in Admin Settings> Reading > Blog pages show at most – 16. So it takes the settings count only.
I need to show the all posts in my page. so what to do for this also?
Kindly answer for these two queries.
- The topic ‘Blog List – Limit’ is closed to new replies.