X7ROOT File Manager
Current Path:
/home/freights/public_html/wp-content/themes/logistik/inc
home
/
freights
/
public_html
/
wp-content
/
themes
/
logistik
/
inc
/
??
..
??
demo-data
??
essential-scripts.php
(3.81 KB)
??
hooks
??
logistik-breadcrumbs.php
(7.27 KB)
??
logistik-commoncss.php
(1.93 KB)
??
logistik-constants.php
(1.67 KB)
??
logistik-framework
??
logistik-functions.php
(32.03 KB)
??
logistik-widgets-reg.php
(4.32 KB)
??
theme-setup.php
(2.35 KB)
??
woo-hooks
??
wp-html-helper.php
(7.86 KB)
??
wp_bootstrap_pagination.php
(2.76 KB)
Editing: wp_bootstrap_pagination.php
<?php // Do not allow directly accessing this file. if ( ! defined( 'ABSPATH' ) ) { exit( 'Direct script access denied.' ); } /** * * @Packge Logistik * @Author Themeholy * @Author URL https//www.angfuzsoft.com * @version 1.0 * */ function logistik_pagination( $args = array() ) { $allowhtml = array( 'p' => array( 'class' => array() ), 'span' => array( 'class' => array(), ), 'a' => array( 'href' => array(), 'title' => array(), 'class' => array(), ), 'br' => array(), 'em' => array(), 'strong' => array(), 'b' => array(), 'li' => array( 'class' => array(), ), ); $defaults = array( 'range' => 4, 'custom_query' => FALSE, 'previous_string' => esc_html__( '«', 'logistik' ), 'next_string' => esc_html__( '»', 'logistik' ), 'before_output' => '', 'after_output' => '' ); $args = wp_parse_args( $args, apply_filters( 'logistik_pagination_defaults', $defaults ) ); $args['range'] = (int) $args['range'] - 1; if ( !$args['custom_query'] ) $args['custom_query'] = $GLOBALS['wp_query']; $count = (int) $args['custom_query']->max_num_pages; $page = intval( get_query_var( 'paged' ) ); $ceil = ceil( $args['range'] / 2 ); if ( $count <= 1 ) return FALSE; if ( !$page ) $page = 1; if ( $count > $args['range'] ) { if ( $page <= $args['range'] ) { $min = 1; $max = $args['range'] + 1; } elseif ( $page >= ($count - $ceil) ) { $min = $count - $args['range']; $max = $count; } elseif ( $page >= $args['range'] && $page < ($count - $ceil) ) { $min = $page - $ceil; $max = $page + $ceil; } } else { $min = 1; $max = $count; } $echo = ''; if ( !empty($min) && !empty($max) ) { for( $i = $min; $i <= $max; $i++ ) { $pagelinkval = (int)$i; if ( $page == $i ) { $echo .= '<li><a class="active">' . esc_html($pagelinkval) . '</a></li>'; } else { $echo .= sprintf( '<li><a href="%s">%s</a></li>', esc_url( get_pagenum_link($i) ), esc_html($pagelinkval) ); } } } if ( isset($echo) ) return wp_kses( $args['before_output'] . $echo . $args['after_output'], $allowhtml ); }
Upload File
Create Folder