رفتن به مطلب

عدم نمایش pagination در ووکامرس


پست های پیشنهاد شده

سلام

خسته نباشید

بنده یک قالب ووکامرس دارم

ولی در صفحه فروشگاه و یا آرشیو شمارنده صفحه ها نمایش داده نمیشه

فایل آرسیو فروشگاه :

<?php get_header()?>

    <div class="grid-container custom1-breadcrumb">
        <?php if (function_exists('remon_breadcrumbs')) remon_breadcrumbs(); ?>
    </div>
    <main class="wrapper-container">
        <div class="grid-container"><!--START row-->
            <div class="grid-x grid-margin-x">
                <div class="cell small-12 medium-9 large-9"><!--START small-12 medium-9 large-9 columns-->
                    <section>

                        <div class="grid-container box shadow single-content">

                            <div class="grid-x grid-margin-x small-up-1 medium-up-2 large-up-3 post-section">

                                <header class="title-header">
                                    <i class="fa fa-coffee"></i>
                                    <h4>
                                        <?php
                                        if(is_category()){?>
                                            مطالب منتشر شده در دسته ی "<?php single_cat_title();?>"
                                        <?php }
                                        else if( is_tag() ) { ?>
                                            نوشته هایی با برچسب "<?php single_tag_title(); ?>"
                                            <?php /* If this is a daily archive */ } elseif (is_day()) { ?>
                                            بایگانی <?php the_time('j F, Y'); ?>
                                            <?php /* If this is a monthly archive */ } elseif (is_month()) { ?>
                                            بایگانی <?php the_time('F, Y'); ?>
                                            <?php /* If this is a yearly archive */ } elseif (is_year()) { ?>
                                            بایگانی<?php the_time('Y'); ?>
                                            <?php /* If this is an author archive */ } elseif (is_author()) {
                                            $curauth = (isset($_GET['author_name'])) ? get_user_by('slug', $author_name) : get_userdata(intval($author));
                                            echo 'بایگانی نویسنده: "'.$curauth->nickname.'"';
                                            ?>
                                            <?php /* If this is a paged archive */ } elseif (isset($_GET['paged']) && !empty($_GET['paged'])) {?>
                                            بایگانی مطالب سایت
                                        <?php }
                                        ?>
                                    </h4>
                                </header>

                                <?php if (have_posts()):  while (have_posts()): the_post()?>
                                    <div class="cell">
                                            <article class="box post-article">
                                                <header class="entry-header">
                                                    <figure class="box-image  thumbnail">
                                                        <img src="<?php the_post_thumbnail_url('post_image')?>" alt="<?php the_title()?>" title="<?php the_title()?>"/>
                                                        <a href="<?php the_permalink()?>" title="<?php the_title()?>"></a>
                                                    </figure>

                                                    <h2>
                                                        <a href="<?php the_permalink()?>" target="_blank" title="<?php the_title()?>">
                                                            <?php the_title()?>
                                                        </a>
                                                    </h2>
                                                </header><!-- .entry-header -->
                                                <div class="post_times">
                                                	<i class="fa fa-calendar" aria-hidden="true">
                                                	</i>
                                                	<time datetime="<?php the_time('F j, Y');?>">
                                                <?php the_time('F j, Y');?>	
                                                	</time>
                                                </div>
                                                
                                                <div class="post_times">
                                                	<i class="fa fa-bar-chart" aria-hidden="true">
                                                	</i>
                                                	بازدید : <?php echo get_post_views (get_the_ID()); ?>
                                                </div>
                                                <div class="entry-content">
                                                    
                                                        <?php echo replywp_excerpt('999','...');?>
                                                    
                                                </div><!-- .entry-content -->
                                                <!--More Link-->
                                                <div class="readmore"><a title="<?php the_title();?>" href="<?php the_permalink();?>">ادامه مطلب</a></div>
                                            </article>
                                        </div>
                                <?php endwhile; endif; ?>

                            </div>
                            <div class="clear"></div>
                            <?php if (function_exists('wp_corenavi')) wp_corenavi(); ?>
                            <div class="clear"></div>
                        </div>
                    </section>
                </div><!--end small-12 medium-9 large-9 columns-->

                <?php get_sidebar()?>
            </div>
        </div><!--END row-->


    </main>

<?php get_footer()?>

و کد فانکشن مربوط به page navi :

function wp_corenavi() {  
  global $wp_query, $wp_rewrite;  
  $pages = '';  
  $max = $wp_query->max_num_pages;  
  if (!$current = get_query_var('paged')) $current = 1;  
  $a['base'] = str_replace(999999999, '%#%', get_pagenum_link(999999999));  
  $a['total'] = $max;  
  $a['current'] = $current;  
  
  $total = 1; 
  $a['mid_size'] = 5; 
  $a['end_size'] = 1; 
  $a['prev_text'] = '<i class="fa fa-angle-double-left"></i>';
  $a['next_text'] = '<i class="fa fa-angle-double-right"></i>';
  
  if ($max > 1) echo '<div class="wp-pagenavi"><div class="navipanel">';  
  echo $pages . paginate_links($a);  
  if ($max > 1) echo '</div></div>';  
}

لطفا کمک کنید ممنون

لینک به ارسال

ببخشید کد آرشیو محصولات رو اشتباه وارد کردم

کد :

<?php get_header()?>

    <div class="grid-container custom1-breadcrumb">
        <?php if (function_exists('remon_breadcrumbs')) remon_breadcrumbs(); ?>
    </div>
    <main class="wrapper-container">
        <div class="grid-container"><!--START row-->
            <div class="grid-x grid-margin-x">
                <div class="cell small-12 medium-9 large-9"><!--START small-12 medium-9 large-9 columns-->
                    <section>

                        <div class="grid-container box shadow single-content">

                            <div class="grid-x grid-margin-x small-up-1 medium-up-2 large-up-3 post-section">

                                <header class="title-header">
                                    <i class="fa fa-coffee"></i>
                                    <h4>
                                        <?php
                                    echo get_the_title();
                                        if(is_category()){?>
                                            مطالب منتشر شده در دسته ی "<?php single_cat_title();?>"
                                        <?php }
                                        else if( is_tag() ) { ?>
                                            نوشته هایی با برچسب "<?php single_tag_title(); ?>"
                                            <?php /* If this is a daily archive */ } elseif (is_day()) { ?>
                                            بایگانی <?php the_time('j F, Y'); ?>
                                            <?php /* If this is a monthly archive */ } elseif (is_month()) { ?>
                                            بایگانی <?php the_time('F, Y'); ?>
                                            <?php /* If this is a yearly archive */ } elseif (is_year()) { ?>
                                            بایگانی<?php the_time('Y'); ?>
                                            <?php /* If this is an author archive */ } elseif (is_author()) {
                                            $curauth = (isset($_GET['author_name'])) ? get_user_by('slug', $author_name) : get_userdata(intval($author));
                                            echo 'بایگانی نویسنده: "'.$curauth->nickname.'"';
                                            ?>
                                            <?php /* If this is a paged archive */ } elseif (isset($_GET['paged']) && !empty($_GET['paged'])) {?>
                                            بایگانی مطالب سایت
                                        <?php }
                                        ?>
                                    </h4>
                                </header>

                                                <?php
                                            $args = array( 'post_type' => 'product', );
                                    $loop = new query_posts( $args );
                                    while ( $loop->have_posts() ) : $loop->the_post(); global $product; ?>
                                      <?php get_template_part('woocommerce/loop-product')?>
                                    <?php endwhile; ?>
                                    <?php wp_reset_postdata(); ?>

                            </div>
                            <div class="page-nav">
                                <?php if (function_exists('wp_corenavi')) wp_corenavi(); ?>
                            </div>
                        </div>
                    </section>
                </div><!--end small-12 medium-9 large-9 columns-->

                <?php get_sidebar()?>
            </div>
        </div><!--END row-->


    </main>

<?php get_footer()?>

 

لینک به ارسال

به گفتگو بپیوندید

هم اکنون می توانید مطلب خود را ارسال نمایید و بعداً ثبت نام کنید. اگر حساب کاربری دارید، برای ارسال با حساب کاربری خود اکنون وارد شوید .

مهمان
ارسال پاسخ به این موضوع ...

×   شما در حال چسباندن محتوایی با قالب بندی هستید.   حذف قالب بندی

  تنها استفاده از 75 اموجی مجاز می باشد.

×   لینک شما به صورت اتوماتیک جای گذاری شد.   نمایش به صورت لینک

×   محتوای قبلی شما بازگردانی شد.   پاک کردن محتوای ویرایشگر

×   شما مستقیما نمی توانید تصویر خود را قرار دهید. یا آن را اینجا بارگذاری کنید یا از یک URL قرار دهید.

×
×
  • اضافه کردن...