Menu
show-notice
hide-notice

5 Different Styles of Page Navigation For Blogger V2

on 1 January 2013

First of all Happy New Year. Today I came up with 5 different styles of page navigation. Actually I have posted an tutorial for adding page navigation which will replace default pager links with numbered page navigation. It maybe feeling boor, for example: if a visitor want to get 5th page of a blog is difficult to get that page because visitor want to click older link again and again. So to abolish such things we have to implement numbered page navigation in blog. This tutorial will avoid that problem by adding this widget. You can select any one of 5 different styles that I had mentioned below. It is easy to add on your blog. Make something changes in your blog on the new year. Let's try it now..

How To Add Page Navigation in Blogger

1. Go to Blogger dashboardTemplate > Edit HTML > Check mark Expand Widget Templates and Find Below code.
<b:includable id='mobile-index-post' var='post'>
2. Paste below code before the above line.
<b:includable id='page-navi'>
<div class='pagenavi'>
<script type='text/javascript'>
var pageNaviConf = {
perPage: 7,
numPages: 5,
firstText: "First",
lastText: "Last",
nextText: "»",
prevText: "«"
}
</script>
<script src='http://awesome-navigation.googlecode.com/files/onlinetrick.js' type='text/javascript'/>
<div class='clear'/>
</div>
</b:includable>
Customize above code if you want to change following:
perpage : How many posts per page you want to display. You can change 7 (in blue color)
numpage : How many number will show in your page Navigation. You can change 5 (in red color)
3. Once again find the below code.
<b:include name='nextprev'/>
4. Replace above code with following code.
<b:if cond='data:blog.pageType == &quot;index&quot;'>
<b:include name='page-navi'/>
<b:else/>
<b:if cond='data:blog.pageType == &quot;archive&quot;'>
<b:include name='page-navi'/>
</b:if>
<b:else/>
<b:if cond='data:blog.pageType == &quot;item&quot;'>
<b:include name='nextprev'/>
</b:if>
</b:if>
5. Now Find  ]]></b:skin>  and add one of the following css style code to your blogger blog.

Style #1

#blog-pager, .pagenavi {
     clear: both;
     text-align: center;
     margin: 30px auto 10px;
}
#blog-pager a, .pagenavi span, .pagenavi a {
text-decoration: none;
color: #333;
text-shadow: 0 1px 0 rgba(255, 255, 255, .5);
background-color: #F8F8F8;
filter: progid:DXImageTransform.Microsoft.Gradient(GradientType=0,StartColorStr=#fffcfcfc,EndColorStr=#fff8f8f8);
background-image: -moz-linear-gradient(top,#FCFCFC 0,#F8F8F8 100%);
background-image: -ms-linear-gradient(top,#FCFCFC 0,#F8F8F8 100%);
background-image: -o-linear-gradient(top,#FCFCFC 0,#F8F8F8 100%);
background-image: -webkit-gradient(linear,left top,left bottom,color-stop(0,#FCFCFC),color-stop(100%,#F8F8F8));
background-image: -webkit-linear-gradient(top,#FCFCFC 0,#F8F8F8 100%);
background-image: linear-gradient(to bottom,#FCFCFC 0,#F8F8F8 100%);
padding: 5px 10px;
border: 1px solid lightGrey;
font-weight: bold;
font-size: 12px;
vertical-align: middle;
-moz-border-radius: 2px;
-webkit-border-radius: 2px;
border-radius: 2px;
margin: 2px 2px;
-webkit-transition: .0s ease-in!important;
-moz-transition: .0s ease-in!important;
-ms-transition: .0s ease-in!important;
-o-transition: .0s ease-in!important;
transition: .0s ease-in!important;
}
#blog-pager a:hover, .pagenavi a:hover {
border-color: #C6C6C6;
filter: progid:DXImageTransform.Microsoft.Gradient(GradientType=0,StartColorStr=#fff8f8f8,EndColorStr=#ffeeeeee);
background-image: -moz-linear-gradient(top,#F8F8F8 0,#EEE 100%);
background-image: -ms-linear-gradient(top,#F8F8F8 0,#EEE 100%);
background-image: -o-linear-gradient(top,#F8F8F8 0,#EEE 100%);
background-image: -webkit-gradient(linear,left top,left bottom,color-stop(0,#F8F8F8),color-stop(100%,#EEE));
background-image: -webkit-linear-gradient(top,#F8F8F8 0,#EEE 100%);
background-image: linear-gradient(to bottom,#F8F8F8 0,#EEE 100%);
}
#blog-pager-older-link, #blog-pager-newer-link {
     float: none;
}
.pagenavi .current {
border-color: #C6C6C6;
background-color: #E9E9E9;
background-image: none;
-moz-box-shadow: inset 0 1px 1px rgba(0,0,0,.20);
-ms-box-shadow: inset 0 1px 1px rgba(0,0,0,.20);
-webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, .20);
box-shadow: inset 0 1px 1px rgba(0, 0, 0, .20);
}
.pagenavi a:active {
border-color: #C6C6C6;
background-color: #E9E9E9;
background-image: none;
-moz-box-shadow: inset 0 1px 1px rgba(0,0,0,.20);
-ms-box-shadow: inset 0 1px 1px rgba(0,0,0,.20);
-webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, .20);
box-shadow: inset 0 1px 1px rgba(0, 0, 0, .20);
}

Style #2

#blog-pager, .pagenavi {
     clear: both;
     text-align: center;
     margin: 30px auto 10px;
}
#blog-pager a, .pagenavi span, .pagenavi a {
background-color: #3BB3E0;
padding:  5px 10px;
position: relative;
margin: 2px;
font-size: 12px;
text-decoration: none;
color: white;
border: solid 1px #186F8F;
background-image: linear-gradient(bottom, #2CA0CA 0%, #3EB8E5 100%);
background-image: -o-linear-gradient(bottom, #2CA0CA 0%, #3EB8E5 100%);
background-image: -moz-linear-gradient(bottom, #2CA0CA 0%, #3EB8E5 100%);
background-image: -webkit-linear-gradient(bottom, #2CA0CA 0%, #3EB8E5 100%);
background-image: -ms-linear-gradient(bottom, #2CA0CA 0%, #3EB8E5 100%);
background-image: -webkit-gradient( linear, left bottom, left top, color-stop(0, #2CA0CA), color-stop(1, #3EB8E5) );
-webkit-box-shadow: inset 0px 1px 0px #7FD2F1, 0px 1px 0px white;
-moz-box-shadow: inset 0px 1px 0px #7fd2f1, 0px 1px 0px #fff;
box-shadow: inset 0px 1px 0px #7FD2F1, 0px 1px 0px white;
-webkit-border-radius: 5px;
-moz-border-radius: 5px;
-o-border-radius: 5px;
border-radius: 5px;
}
#blog-pager a:hover, .pagenavi a:hover {
background-image: linear-gradient(bottom, #3EB8E5 0%, #2CA0CA 100%);
background-image: -o-linear-gradient(bottom, #3EB8E5 0%, #2CA0CA 100%);
background-image: -moz-linear-gradient(bottom, #3EB8E5 0%, #2CA0CA 100%);
background-image: -webkit-linear-gradient(bottom, #3EB8E5 0%, #2CA0CA 100%);
background-image: -ms-linear-gradient(bottom, #3EB8E5 0%, #2CA0CA 100%);
background-image: -webkit-gradient( linear, left bottom, left top, color-stop(0, #3EB8E5), color-stop(1, #2CA0CA) );
}
#blog-pager-older-link, #blog-pager-newer-link {
     float: none;
}
.pagenavi .current {
background-image: linear-gradient(bottom, #3EB8E5 0%, #2CA0CA 100%);
background-image: -o-linear-gradient(bottom, #3EB8E5 0%, #2CA0CA 100%);
background-image: -moz-linear-gradient(bottom, #3EB8E5 0%, #2CA0CA 100%);
background-image: -webkit-linear-gradient(bottom, #3EB8E5 0%, #2CA0CA 100%);
background-image: -ms-linear-gradient(bottom, #3EB8E5 0%, #2CA0CA 100%);
background-image: -webkit-gradient( linear, left bottom, left top, color-stop(0, #3EB8E5), color-stop(1, #2CA0CA) );
}

Style #3

#blog-pager, .pagenavi {
     clear: both;
     text-align: center;
     margin: 30px auto 10px;
}
#blog-pager a, .pagenavi span, .pagenavi a {
border: 1px solid #3d8bf2;                
padding: 5px 10px;                 
text-decoration: none;                 
font-family: arial;                 
color:#fff;                 
margin: 2px;                 
background-image: url('http://onlinetrick-ot.googlecode.com/svn/image/menubg1.PNG');
background-position: left;            
-webkit-transition: all 0.7s ease-in-out;               
-moz-transition: all 0.7s ease-in-out;                 
-o-transition: all 0.7s ease-in-out;  
}
#blog-pager a:hover, .pagenavi a:hover {
background-position:right; 
}
#blog-pager-older-link, #blog-pager-newer-link {
     float: none;
}
.pagenavi .current {
background-position:right; 
}

Style #4

#blog-pager, .pagenavi {
     clear: both;
     text-align: center;
     margin: 30px auto 15px;
}
#blog-pager a, .pagenavi span, .pagenavi a {
border: 1px solid #3d8bf2;                
padding: 5px 10px;                 
text-decoration: none;                 
font-family: arial;                 
color:#fff;                 
margin: 2px;                 
background-image: url('http://onlinetrick-ot.googlecode.com/svn/image/menubg2.PNG');
background-position: bottom;         
-webkit-transition: all 0.7s ease-in-out;               
-moz-transition: all 0.7s ease-in-out;                 
-o-transition: all 0.7s ease-in-out;  
}
#blog-pager a:hover, .pagenavi a:hover {
background-position:top;
}
#blog-pager-older-link, #blog-pager-newer-link {
     float: none;
}
.pagenavi .current {
background-position:top; 
}

Style #5

#blog-pager, .pagenavi {
     clear: both;
     text-align: center;
     margin: 30px auto 15px;
}
.pagenavi .pages {
display: none;
}
#blog-pager a, .pagenavi span, .pagenavi a {
padding: 5px 10px;
text-decoration: none;
font-family: arial;
color: white;
margin: 2px;
background: black;
background-position: bottom;
-webkit-transition: all 0.3s ease-in-out;
-moz-transition: all 0.3s ease-in-out;
-o-transition: all 0.3s ease-in-out;
border-radius: 30px;
font-size: 20px;
}
#blog-pager a:hover, .pagenavi a:hover {
background: orange;
}
#blog-pager-older-link, #blog-pager-newer-link {
     float: none;
}
.pagenavi .current {
background: orange;
}
If there is an bug in the code you comment it below..

SHARE

81 comments:

  1. realy thannk you so much...
    this page navigation is realy helpfull...

    ReplyDelete
  2. Awesome widget!..
    i was Looking for this!!...
    Many thanks Brother..
    your blog is really Gr8..

    ReplyDelete
  3. This looking very awesome. Thanks for sharing... I always like this blog..

    ReplyDelete
  4. I'm glad to saw your comment.
    I will post about showing short summary instead of full post on index page soon, Thanks.

    ReplyDelete
  5. HOW TO EDIT NEWER,HOME,AND PREVIOUS POST BUTTON IN STYLE 1

    ReplyDelete
    Replies
    1. That I already customized in style #1 with background and color.... Or if your doubt is another one, then let me know by replying this comment...

      Delete
    2. i want to change that to png button ? can you help me? and may i ask question ?? ai want add tab view to my blog,, but i use template from artister,, and i can't finde siber-wrapper?? can you help me?

      Delete
    3. This comment has been removed by the author.

      Delete
    4. Does this page navigation work with 2000+ posts? Thank you.

      Delete
  6. This comment has been removed by the author.

    ReplyDelete
  7. 10000 Thanks,Its great Finally i found a very good post,i added this in my blog called www.quizvook.com .

    ReplyDelete
  8. Hello!

    My site - http://www.arabmoviez.org/ - has 1850 articles, but navigator shows only 500 ( 50 pages x 10 articles on each = 500 articles)?

    Pls, help me. What can I do?

    Thank you!

    ReplyDelete
  9. Awesome work.. works flawless.
    Thanks

    ReplyDelete
  10. Check mark Expand Widget Templates is not present in my blog and i am also unable to find this code in edit html part
    please help me

    ReplyDelete
    Replies
    1. Sorry, Expand Widget Templates is not present in new Template HTML Editor. This post was published before releasing the New HTML Editor by blogger team. So you don't need do that step just find code in the template and follow all other steps. That's all...

      Delete
  11. This works properly.....

    Thanks for sharing

    ReplyDelete
  12. newblogplus.blogspot.in

    ReplyDelete
  13. Hey Softglad,
    i successfully added numbered navigation to my blog but i had problem while installing the Style....
    please help me guys

    ReplyDelete
    Replies
    1. You have to select only one CSS style code out of five, and add it in your template before b skin.

      Delete
    2. ya i did the same but it's not showing any Style just simple no. like that
      "12345 Last"

      Delete
    3. Yes it is fixed, try it again...

      Delete
  14. AnonymousMay 11, 2013

    Not Working Man Help Me i Want This I Creating The Template But The Older ,Home And Newer link is hide how to add this please help me

    ReplyDelete
    Replies
    1. Yes it is fixed, try it again, Sorry for the inconvenience....

      Delete
  15. The widget with id "Blog1" contains at least two b:includable elements with the same id: "page-navi". All b:includable elements should have a unique id for a given widget.

    WHY?????

    ReplyDelete
    Replies
    1. Because under Blog1 can be accommodate only one page navigation, So in your template an old page navigation already existing. First of all remove that old page navigation code from your template and try this code.

      Delete
    2. the markup in the document following the root element must be well-formed. ????????

      Delete
  16. Thanks. Loved this man, great code!

    ReplyDelete
  17. Bombastic.... I was looking for this for a long time and I even didn't know the name of this widget, but thanks God I found your blog. It's just amazing... worked well on my blog bishots.com.

    Keep up the great work. You're awesome,

    ReplyDelete
  18. AnonymousJune 01, 2013

    Thanks bro

    ReplyDelete
  19. realy good stuff. thanks

    ReplyDelete
  20. AnonymousJune 07, 2013

    Bro its not showing up in my blog.
    Instead the older post and home links have dissapeared.
    Now there is no page navigator at all. :(

    ReplyDelete
  21. This comment has been removed by a blog administrator.

    ReplyDelete
  22. Nice but sir it is not showing the text that says "page 1 of 7". why?

    ReplyDelete
    Replies
    1. You just added CSS style #3 only. Your blog has not included my page navigation script. Your blog's page navigation is another one apart from this widget. Remove old widget and follow the steps 1 to 4 and select any style.

      Delete
  23. Great!! I will try this, Thanks!

    ReplyDelete
  24. Thank you very very very much bro.....

    ReplyDelete
  25. hello ! is there anyway to change next previous in my language? (Greek)thanks

    ReplyDelete
    Replies
    1. Definitely you can change. Replace those two arrow with your own words in step #2. That are below: Please refer bold text arrows.
      nextText: "»",
      prevText: "«"

      Delete
  26. How can one not limit the number of pages in navigation...

    Please check my site at www.indiantaxhome.com

    ReplyDelete
    Replies
    1. Please explain once more. I didn't get your words..

      Delete
    2. My site www.indiantaxhome.com has more than 163 pages, considering 9 post per page .... but after using style 1 and the given code above... my website www.indiantaxhome.com shows only 56 pages.... please could you check and reply why is it so.

      Delete
  27. Plaese help me!

    mysite: http://demonavi.blogspot.com/

    my error: The widget with id "Blog1" cannot contain element: "#comment". A widget can only contain b:includable elements

    ReplyDelete
  28. Really Good stuff! One question, how do I change the order of my posts. For example - my newest post I want to be a higher # then my first post. Thanks for your help.

    ReplyDelete
  29. Thank you very much, i used this and it's work like charm. Really appreciate your hard work! God Bless

    ReplyDelete
  30. Really helpful and also easy to follow the instructions, check it out at http://flygadget.com
    Cheers

    ReplyDelete
  31. Did't work for me. I used num5 style

    ReplyDelete
    Replies
    1. I fixed. Actually The Older Posts and Newer Post was still there, because of the code and some condition.
      Thanks

      Delete
  32. Your article is very informative, specially to the new individual entering to the field of blogging..... Make Money , Blogging Tips

    ReplyDelete
  33. sorry sir it's not working in my blog

    ReplyDelete
  34. Hello bro, i am facing a serious problem via this navigation menu, while i change the navigation menu the main title of my blog show the url of the nav link like "http://stensly.blogspot.com/search?updated-max=2013-11-06T20%3A07%3A00%2B05%3A45&max-results=10"

    please provide me the solution for it.

    ReplyDelete
  35. Works for me..Thanks man..

    ReplyDelete
  36. Man! I like your blog very much

    VISIT MY BLOG ALSO

    www.10magictricks.blogspot.com

    ReplyDelete
  37. Hey, I've tried this on my blog, but it does not show up properly... instead, the "newer" "older" links disappeared. I tried everything, but I just can't find the error. I would be glad if you had a look..

    this is my page (it's in german, hope you don't mind) http://getundressed.blogspot.com

    Thank you so much!

    ReplyDelete
    Replies
    1. Ok, so right after posting this, I somehow fixed the problem.. still don't know what I did, but it worked out for me haha

      Again, thanks so much for sharing this page navigation!

      Delete
  38. It’s awesome to pay a visit this site and reading the views of all mates regarding this piece of writing, while I am also zealous of getting know-how.
    website design

    ReplyDelete
  39. it messed up my mobile navigation ! how to fix it on mobile template..

    ReplyDelete
  40. The widget with id "Blog1" contains at least two b:includable elements with the same id: "page-navi". All b:includable elements should have a unique id for a given widget :(

    ReplyDelete
  41. Thanks brilliant blog and written in good understandable language, can you help me to know how to upload javascript files onto blogger's blog, how to to do it thanks in advance.

    ReplyDelete
  42. Thanky you somuch it very useful for my blog.

    ReplyDelete
  43. You, my dear sir, rule. You know that? Because if you don't, you should know. Because you do - you rule.:D THANK YOU.

    ReplyDelete
  44. 5. Now Find ]]> and add one of the following css style code to your blogger blog.

    but, replace/above/bellow ?

    ReplyDelete
  45. Thank you for this. It works perfect for my blog. God bless!

    ReplyDelete
  46. This does not render well when using the mobile view. What can I do to modify it?

    ReplyDelete
  47. Dear My site www.indiantaxhome.com has more than 163 pages, considering 9 post per page .... but after using style 1 and the given code above... my website www.indiantaxhome.com shows only 56 pages.... please could you check and reply why is it so. Awaiting Reply

    ReplyDelete
  48. i had a problem with this code.. the final code doesnt turns blue in colur n code doesnt work fo me

    ReplyDelete
  49. Hi, thank you for the tutorial. However, I tried to follow the instruction and applied the script on my blog, it is not working. Can you take a look of it?
    http://yesstyles.blogspot.com/

    Thank you.

    ReplyDelete
  50. the numbered navigation seems to be on every page but when a comment form is present numbers are gone and are replaced by home, next, prev buttons. also when clicking a popular post widget to get to a page the numbers are also replaced by home button etc. why is this? is there any way to have numbers of page appear always on every page no matter how you get to the page or whether a comment form is present or not? Thank you very much. greatly appreciated.

    ReplyDelete
  51. the numbered navigation seems to be on every page but when a comment form is present numbers are gone and are replaced by home, next, prev buttons. also when clicking a popular post widget to get to a page the numbers are also replaced by home button etc. why is this? is there any way to have numbers of page appear always on every page no matter how you get to the page or whether a comment form is present or not? Thank you very much. greatly appreciated.

    ReplyDelete
  52. Hello
    Thanks for the tutorial.
    I number 5 style.
    After many attempts, two days 4 hours 8 hours in total, I got it to work.
    The fact is that I saved the template and download. I upload  this template on another blog test and does not work. And it is exactly the same as above.
    What I do not understand is not work. What's worse is that I should go to my blog template and not work.
    I took 8 hours doing it again and does not work.
    I have a simple template blogger.
    The test is private blog.
    If you want I send you an invitation

    ReplyDelete
  53. how to hide first and last button from the page navigation

    ReplyDelete
  54. Very useful information
    http://hd-wallpaperhub.blogspot.com/

    ReplyDelete
  55. Hey guys! you should check the blog you will find interesting things
    http://namesbymudassar.blogspot.com/

    ReplyDelete
  56. Hi, i used this code on my blog. its working .. but not properly...i have 100 posts in my blog..
    i set perPage=10; but its not working, its showing only 7 or 6 or 8. not showing 10.. what is the problem.. please help me on this. my blog is http://uxfrujfhjxsfhxsfhx.blogspot.in/

    ReplyDelete
  57. This comment has been removed by the author.

    ReplyDelete

Important -Comments with Links will be deleted immediately upon our review and If you are asking a question click the 'Subscribe By Mail' link below the comment form to be notified of replies.