In this tutorial, we will see How to Setup Pagination on the Home Page of your Blog or Website running on the Thesis Theme for WordPress. This will replace the regular “Previous Entries” link that appears at the bottom of your Content Area, just below the Teasers (if you are using them).
What are we trying to create?
Install the WP Navigation Plugin
To setup pagination on your WordPress Blog, we need to install the WP-Navigation Plug-in.
You can download the Plug-in from its Home Page -http://www.lesterchan.net/wordpress/readme/wp-pagenavi.html
Follow the instructions on the Plug-in page for installation. Note there are different versions of the plug-in, for various WordPress versions. Choose the right one based on your WordPress install.
Default settings and options for the plug-in is sufficient to get started. If you need further changes, options are available under Settings – PageNavi in your WordPress Admin Dashboard
Proceed further only if the plug-in is successfully installed and activated.
Add code to custom_functions.php
Add the following code to custom_functions.php file. You can find this file in the following path –
/* Pagination */ function my_thesis_pagination() { echo ""; wp_pagenavi(); echo ""; } remove_action('thesis_hook_after_content','thesis_post_navigation'); add_action('thesis_hook_after_content', 'my_thesis_pagination');
Add styles to custom.css
Add the following code to custom.css file. You can find this file in the following path –
/* Page Navigation */ .custom .full_width #content_box .wp-pagenavi .page { margin: 2px; padding: 2px 4px; }
Further Styling up the Pagination Bar
With the default installation, your pagination bar looks something like this.
If you like to try your hand at CSS, then the pagination bar can be further styled by making changes to the following file:
Get in touch with me, if you need any help in styling the pagination bar.
Hope you found this simple tutorial useful. Share it on social media using the tools given below, so that more Thesis folks might use it!
- Create a Full-Height Sidebar and Full-Width Navigation Menu in Thesis Theme
- Search Box in Navigation Bar of the Thesis Theme
- Setup a Header Banner Image for your blog using Thesis Theme
- Hide Dates in Old WordPress Posts using Thesis Theme
- Create a Killer Services and Portfolio Page with Thesis Theme
Previous post: Why should you try Readtwit?
Next post: 5 Quick Ways to make your Blog Extremely Popular