Skip to content

Instantly share code, notes, and snippets.

@trangsihung

trangsihung/style.css Secret

Last active Jul 26, 2017
Embed
What would you like to do?
phan-trang-wordpress-khong-dung-plugin.html
.page_nav .page-numbers{
background:#BCBCBC;
color:#fff;
display:block;
width:auto;
float:left;
margin: 4px 4px 4px 0;
padding:15px 18px 14px 18px;
text-decoration:none;
}
.page_nav .page-numbers:hover{
background: #24221D;
color:#fff;
text-decoration: none;
}
.page_nav .current{
background: #24221D;
color:#fff;
padding:15px 18px 14px 18px;
}
<?php
if ( ! function_exists( 'wplift_pagination' ) ) {
function wplift_pagination() {
global $wp_query;
$big = 999999999;
echo '<div class="page_nav">';
echo paginate_links( array(
'base' => str_replace( $big, '%#%', esc_url( get_pagenum_link( $big ) ) ),
'format' => '?paged=%#%',
'current' => max( 1, get_query_var('paged') ),
'total' => $wp_query->max_num_pages ) );
echo '</div>';
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment