Pagenav Not appearing on custom Template

Your navigation function seems to take data from main query (global $wp_query) variable. However what you have on custom page is a completely separate query (new WP_Query()), which doesn’t modify main one (as it shouldn’t). The best way would probably be to modify your pagination function to optionally accept custom query object as argument to … Read more

Pagination on Custom Loop

function dot1_get_nav(){ if ( get_next_posts_link() || get_previous_posts_link() ) { ?> <nav class=”dot1-navigation clearfix”> <?php if ( get_next_posts_link() ) { ?> <div class=”alignleft”> <?php next_posts_link( __( ‘&larr; Older Entries’, ‘dot1’ ) ); ?> </div> <?php } ?> <?php if ( get_previous_posts_link() ) { ?> <div class=”alignright”> <?php previous_posts_link( __( ‘Newer Entries &rarr;’, ‘dot1’ ) ); ?> … Read more

How to fix pagination for custom loops?

The Problem By default, in any given context, WordPress uses the main query to determine pagination. The main query object is stored in the $wp_query global, which is also used to output the main query loop: if ( have_posts() ) : while ( have_posts() ) : the_post(); When you use a custom query, you create … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)