$pages
is an optional parameter.
If not set, $pages
will equal an empty string.
So if($pages == '')
checks to see if that parameter has been set.
In this call, the parameter has not been set: kriesi_pagination();
In this call, the parameter has been set: kriesi_pagination(5);
In the tutorial link that you posted, read this section again, the part that starts
As you can see we got 2 optional parameters to pass:
Related Posts:
- Modify previous and next text from pagination links
- Getting paginate_links() ‘end_size’ to display none
- WordPress AJAX Pagination with query_posts
- How to implement WP_List_Table? WP_List_Table giving array instead of a value in listing table
- Static Frontpage Pagination – Custom loop
- I can’t fetch query parameters ($_GET parameters) with get_query_var
- Rewriting search and pagination base
- WooCommerce – Customer Order History Pagination
- Changing Link Attributes for Wp_Link_Pages
- Custom Loop Pagination on WordPress
- Edit format of Paginate_Links()
- Pagenavi pagination via wp-query in functions.php showing same content for each page
- How to check if comments are paginated?
- get understrap pagination to work with custom query
- Customized title tag for each page in pagination?
- Add “last” and “first” to WordPress Comment Pagination Links
- WordPress get pagination on wpdb get_results
- Sorting Posts | Alphabetical Order
- Getting rid of role=”navigation” in the Home Page Pagination
- Page navigation not showing even tho it should
- How to get the Page Number of the Current Page in Single Post Pagination
- How can I add pagination and how can I change thumbnail size?
- WP-PageNavi is showing the first page only
- How can I properly control the numbers and dots that appear in pagination?
- Increase returned number/pages on pagination
- Adding nofollow to a PHP generated Nav
- Using loop pagination on single.php
- WordPress 3.2 query_posts and pagination, permalinks issue
- Unreadable pagination
- How to show all pages in blog navigation?
- get_terms pagination
- Search not showing all results
- Pagination in plugin’s backend
- PHP code to use on next & previouspage links
- Pagination for custom shop loop woocommerce
- How to get all author posts outside of author templates
- How to create pagination for users list using custom array?
- Custom Pagination is Broken
- Pagination on Custom Post
- Next post link on a bootstrap button
- 2nd page displaying the exact same posts as my first page (minus the very first post)
- Prev/Next Links Broken on Static Front Page Pagination
- Rewrite with pagination /foo/page/2/ to posts of a given category, page 2
- the_posts_pagination() not working in wpquery
- ACF Repeater Pagination stopped working since upgrade to php7.2
- Generating rel=”prev” and rel=”next” using filters
- Need help with Code Correction php+wordpress
- Custom query vars filters problem with pagination
- How to Handle Going Backwards in Navigation When Referrer in PHP/JavaScript won’t work?
- Need help with pagination
- Custom pagination (Previous / Next)
- WordPress pagination not working in search result page
- Remove Post if Advanced Custom Field is checked to fix paging
- How to add PHP pagination to wordpress
- pagination broken – clicking next displays “page not found”
- page 1 is not paged
- Pagination stays on same page for post category
- Pagination Not Working (pages duplicating content)
- Pagination in single.php
- Pagination at category doesnt work with same name of page
- How to work Woocommerce pagination inside shortcode?
- Help to modify wp_link_pages()
- How do I get pagination for get_posts() in WordPress or do I have to rewrite the whole code?
- Pagination contents not changing in Front page WordPress
- Load more posts using AJAX based on posts inside WP_Query
- How to stop hiding buttons forward / backward in pagination?
- How to make a pagination with dropdown selection?
- static page pagination not working
- Trying to get pagination working on WP_Query() post grid
- AJAX numerical pagination problem in TwentyFifteen-child theme
- Pagination 404 error(I have refreshed the permalinks and tried several previous options)
- Pagination – Previous link is not show and Next link sticks at page 2
- Top Authors list by highest post views with Ajax pagination
- How can I get my pagination loop to display the correct number of total pages?
- Following/Followers Users list Using Ajax Pagination inside Author Profile
- WordPress Single Post Pagination Numbered and Navigational
- Exclude a category slug on pagination
- Add a leading zero to pagination
- Get current_post in reverse order with pagination
- Apply filters when loading post via ajax
- offset and max_num_pages in pagination gallery
- rewrite_rule – working fine but broken for pagination
- How to fix blank pagination links?
- WordPress pagination broken on blog page, working for search results page
- Pagination on Custom Loop
- How can i list all user registered on my website and have pagination [duplicate]
- Pagination not displaying
- WordPress post pagination on custom template not working
- Pagination in category.php not functioning
- How to add pagination for wordpress home page
- Pagination 404 on my index.php
- Infinite Scroll Plugin: How to first show 6 posts and then 2 posts thereafter with Infinite Scroll Plugin?
- Pagination not working properly
- paginate_links() returns NULL instead of the pagination links, but pagination is actually happening
- Blog Posts not sorted and pagination not adjusted after filtering some category
- How to Set Page Pagination Using Ajax JQuery – WordPress
- /page/2/ redirect to 404
- Why do I get a 404 error on my custom post type archive pagination?
- Sort registered users by post count? (inside admin dashboard)
- How to abort saving data in save_extra_profile_fields function WordPress?