Check for is_front_page()
and if you want to catch the first page only inspect get_query_var( 'paged' )
too:
if ( is_front_page() and 2 > get_query_var( 'paged' ) )
{
// we are on the first page of the front page
}
Related Posts:
- Insert div after every three posts in home.php [duplicate]
- Return to the beginning of the results of a for loop
- How to count posts posts if they are in a separate content page?
- image on homepage disappeared due to change of permalink name
- Adding PHP to an if else loop
- Accordion headings cuts off to second line on collapsing a accordion heading (used acf repeater)
- WordPress Recent Posts – Loop
- Exclude category and post from loop in custom category.php
- ACF background-color per post in a WordPress loop
- How can I get my pagination loop to display the correct number of total pages?
- Advertisement in Loop Posts wordpress
- How do if all posts has this category ID then do this
- Thumbnail wouldn’t scale to size properly
- ERR_TOO_MANY_REDIRECTS / To Force SSL Logins and SSL Admin Access
- How to sort (orderby) a query done by a template function before the ‘foreach’ loop?
- Date of last blog update for specific authors only?
- View tag description on page
- Making list of posts with chosen description
- Filter loop by ‘price’ with meta_query
- Get current_post in reverse order with pagination
- PHP for loop not working as intended
- How fix error in the WordPress loop?
- what’s the syntax for if the image exists get the image?
- Adding custom PHP to existing loop in Genesis
- How to Pass Current Taxonomy Terms into new WP_Query?
- Problems with the WordPress loop [closed]
- Add div after every 4 posts then every 2 posts for a responsive loop
- Different home page for logged off users
- how to remove replicating a tag inside loop?
- My query keeps looping infinitely ! how to stop it?
- Efficient way of querying for a “fallback” post?
- WordPress while loop with aphabetic counting like one, two, three
- Display product attributes for current product
- Retrieving specific images from Media Library
- For each 3 posts, show a different post type
- Div Missing In Custom Loop Query
- Add post class in custom loop (WP_QUERY)
- Loop 1 user randomly
- Create a hierarchical loop at predefined markup requirements
- enumerating custom taxonomies?
- Loop returns more items than exist?
- Using page template to fetch posts in page
- Modify category archive page loop on functions.php
- Custom Taxonomy Link Text Echo Name Not Slug
- WP_Post is not from correct array
- Post formating on Home page
- divide custom field values in div every two values
- Create Customization Controls from Array
- Adding unique marketing messages between certain products whilst using isotope/Infinite Scroll
- How to display html code on homepage
- Use page.php for front page
- I want my wordpress loop to only display posts of the standard format
- Automatically create a loop for post ID
- WP Knowledge Base Theme bug – Subcategories and Articles, Need to change WP_Query
- Limit ads appearing more than three times
- Problems With Query and/or Template Part and/or PHP
- Two loops in one function
- How to hide something from custom home page with php code?
- ACF loop and php formatting
- How to display thumbnail if post is assigned one otherwise not
- How to have post count after each listed category
- Inserting A Feed and Sidebar into an HTML Page
- How can I put a custom field as the link of a button shortcode?
- Pagination on Custom Loop
- Pagenav Not appearing on custom Template
- Error trying import one category on page
- What is the best way to get the first few post from WordPress in different divs using a loop?
- why is this content-template not showing any of my blog-entries?
- Transient Loop Not working as expected
- the_post_thumbnail unless video id is added
- Advanced Taxonomy query, with 3 post types
- Remove the_content From Loop
- Trying to display ads on only a third of posts in a loop. Keep getting Error 500?
- Custom Meta Box If Else Statement
- Custom single.php files for different post formats
- Tables not showing divs and loop/php items
- How to call the_author_meta and make it work?
- I want Page titles and excerpts to show up on home.php in certain order
- Troubleshooting “loopback requests that take too long”
- Why does a meta_query break this WP_Query?
- Conditional in foreach loop is outputting content twice
- WordPress post pagination on custom template not working
- Alternative loop syntax error [closed]
- Pagination in category.php not functioning
- is there away to hide php code in wordpress not to show in PAGES
- Implement “No related posts for this entry” into the loop?
- For each loop will not append to the_content hook
- Adding slides to an existing carousel manually
- Excerpt all post content Content Same Size without word cutting off
- How to handle parent and child pages?
- Options.php loop won’t show!
- Loop on a wordpress Page instead of content coming from the WP text editor
- How do I remove blog entries from home page Twenty Eleven child theme?
- How to create a loop where loop changes every post?
- How to create a loop that will display one post and stop?
- Woocommerce linking variations
- Help with if/else loop [closed]
- Pagination not working properly
- $_html is empty when var dumped
- Not able to see the error [closed]