WP Page Numbers
How to check current page number? (1 post)

  1. rizkysyazuli
    Posted 5 years ago #

    how do i do check which page i'm currently on? is there a variable stored by WP Page Numbers that i can use?

    here's my case: i have an introduction content that is showed on the front page. but once users click to the next page, this content should not be visible.

    here's a snippet from my index template:

    <?php if (is_front_page()) : ?>
      // the intro. this should only show up on the first page
    <?php endif; ?>
    <?php if (have_posts()) : ?>
    <?php while (have_posts()) : the_post(); ?>
      // the loop
    <?php endwhile; ?>
    <?php endif; ?>
    <?php if(function_exists('wp_page_numbers')) { wp_page_numbers(); } ?>

    and while we're on the subject.. how do i add the current page numbers to the title tag?



Topic Closed

This topic has been closed to new replies.

About this Plugin

  • WP Page Numbers
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic