Set Fixed Amount Of Posts Displayed On Labels Pages




Step 1. In Your (New Design) Blogger Dashboard Click The Drop Down Menu For Your Blog > Choose Template > Then Edit Html > Now Proceed > Tick The Expand Widget Templates Box. 

Step 2. Find the following code in your blogs html - it will be in your template a few times :
(Click Ctrl + F for a search bar to help find the code !

                                                         expr:href='data:label.url'





Step 3. Replace them all with the blue line following code :

                 expr:href='data:label.url + "?max-results=6"'

Important - Highlighted is the number of posts displayed, it's set as 6.Replace the number 6 with the number of posts you want displayed.

So that will set a number of posts to be displayed in the links automatically generated.By automatically generated i mean labels in a labels gadget in your sidebar or above/below your posts.What if you are adding manually adding labels links to a post, menu or elsewhere ?

Simply add ?max-results=6 to the end of the URL, changing 6 to the number you want.

Post a Comment

 
Top