• Resolved Ian

    (@ianaleksander)


    I’m having a weird issue where paging works fine for some of my categories but not for my blog categories.

    For example:

    https://www.tradereadingorder.com/list/dc-comics-universe/recommended-reading-order/

    and

    https://www.tradereadingorder.com/list/dc-comics-universe/recommended-reading-order/page/2/

    work fine,

    but

    https://www.tradereadingorder.com/blog/ does and

    https://www.tradereadingorder.com/blog/page/2/ does NOT.

    I feel like it must SOMEHOW have something to do with my category-blog.php but I can’t figure out what.

    <?php
    get_header();
    ?>
    <div id="content">
    
    <?php /* If this is a category archive */ if (is_category()) { ?>
    
    <div id="booklist-header">
    <table width="100%" height="159px">
    <tr>
    <td rowspan="2" width="195px" align="left">
    <img src="https://www.tradereadingorder.com/list-image/blog.jpg">
    </td>
    <td align="left">
            <div id="booklist-title"><?php single_cat_title();?>
    </div>
    </td>
    </tr>
    <tr>
    <td align="left">
    <?php echo category_description( $category ); ?>
    </td>
    </table>
    </div>
    
    <?php } ?>
    
    <div id="blog-loop">
    
    <?php if (have_posts()) : while (have_posts()) : the_post(); ?>
    
    <div id="single-post-header">
    <div id="booklist-title"><a href="<?php the_permalink() ?>" rel="bookmark" title="<?php the_title();?>"><?php the_title(); ?></a></div>
    <div class="blog-post-title"><!-- <?php _e("filed in"); the_category(',') ?>--> By <?php the_author_posts_link(); ?> | <?php the_date('l, F j, Y',' ',' '); unset($previousday); ?> | <?php the_time() ?> | <?php comments_popup_link(__('0 Comments'), __('1 Comment'), __('% Comments')); ?> <?php edit_post_link(__('[Edit]')); ?></div>
    </div>
    <div class="blog-post" id="post-<?php the_ID(); ?>">
    
    	<div class="storycontent">
    		<?php the_content(__('(more...)')); ?>
    <div class="feedback">
                <?php comments_popup_link(__('Comment<b>!</b>'), __('1 Comment'), __('% Comments')); ?>
    <br />
    <!-- AddThis Button BEGIN -->
    <?php echo "<div><a class=\"addthis_button\" href=\"https://www.addthis.com/bookmark.php?v=250&username=f4shi0nabl3\" addthis:url=\"".urlencode(get_permalink())."\" addthis:title=\"".urlencode(get_the_title($id))."\"><img src=\"https://s7.addthis.com/static/btn/v2/lg-share-en.gif\" width=\"125\" height=\"16\" alt=\"Bookmark and Share\" style=\"border:0\"/></a><script type=\"text/javascript\" src=\"https://s7.addthis.com/js/250/addthis_widget.js#username=f4shi0nabl3\"></script></div>"; ?>
    <!-- AddThis Button END -->
    	</div>
    	</div>
    
    <table>
    <tr>
    <td> <a href="https://feeds.feedburner.com/tradereadingorder" title="Subscribe to my feed" rel="alternate" type="application/rss+xml"><img src="https://www.tradereadingorder.com/feed-icon-12x12-orange.gif" alt="" style="border:0"/></a>
    </td>
    <td><a href="https://feeds.feedburner.com/tradereadingorder" title="Subscribe to my feed" rel="alternate" type="application/rss+xml"> Want to stay up to date? Click here to subscribe to updates by RSS!</a></td>
    </tr>
    </table>
    <table>
    <tr>
    <td><a href="https://feedburner.google.com/fb/a/mailverify?uri=tradereadingorder&loc=en_US" title="Subscribe by Email"><img src="https://www.tradereadingorder.com/email-icon.gif" style="border:0"></a></a>
    </td>
    <td><a href="https://feedburner.google.com/fb/a/mailverify?uri=tradereadingorder&loc=en_US" title="Subscribe by Email">You can also sign up to get updates by Email! </a></td>
    </tr>
    </table>
    
    </div>
    
    <?php comments_template(); // Get wp-comments.php template ?>
    
    <?php endwhile; ?>
    
    <div id="pagenav"><?php previous_posts_link('Newer Entries');?> | <?php next_posts_link('Older Entries'); ?></div>
    
    <?php endif; ?>
    </div>
    
    <div id="bottom-advertising">
    <script type="text/javascript"><!--
    google_ad_client = "pub-9585424773737554";
    /* Content (Homepage) */
    google_ad_slot = "7668939941";
    google_ad_width = 468;
    google_ad_height = 60;
    //-->
    </script>
    <script type="text/javascript"
    src="https://pagead2.googlesyndication.com/pagead/show_ads.js">
    </script>
    </div>
    
    <br />
    </div>
    
    <?php get_footer(); ?>

    Any ideas? I feel like it’s probably something stupid that I missed.

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter Ian

    (@ianaleksander)

    I tried changing the loop query but that didn’t seem to work.

    Thread Starter Ian

    (@ianaleksander)

    Figured it out, sort of. I had set the permalink structure to be /list/category-name/page/1

    So it wasn’t working with just category-name/page/1

    frustrating, wish it worked with both, but fixing my links to account for that seems to have solved the problem, at least as far as usability goes.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Pages not working in blog categories’ is closed to new replies.