The is_page()
depends on how the request maps to the main query variables, so you could instead check the post type within the loop:
the_title();
if( 'post' === get_post_type() ) {
// display some extra stuff
}
Related Posts:
- A search for ‘0’ returns results
- Using the Loop to show all levels of subpages under a parent page? Halfway there
- Child Pages Loop
- Get post by page name or slug
- Loop that displays PARENT PAGE & CHILD PAGE & outputs GRANDCHILD PAGE title and content
- Display subpages under parent page as a list within a loop
- Is including the loop necessary for page.php? [duplicate]
- Identify the page being shown while in The Loop
- If Loop has odd number of posts on last page Custom style for last post in it
- If No Search Results, Show Posts from Alternate Search Query
- single page site with subpages
- How to loop through ALL pages?
- Custom search form to display users only
- Differentiate between posts and pages in search results
- Loop and Page template : my WP_query don’t take args
- Create a loop that gets pages with their template
- Display content of page template (get_page)
- Loop after page content
- wp alchemy multiple image uploader output images to template
- How to get an array of years from all of the search results, and use it to filter by year the paginated loop?
- How to go about combining dropdowns / filter queries?
- Get search.php results in header.php?
- Filter the_posts doesn’t work on search page
- Get Page content to displayin Bootstrap Modal
- How do I make a variable available inside partials?
- Exclude page name from loop
- Stepping through a foreach loop – adding +1 to the end of it so next time it loops it starts on item 2
- Include multiple page ids in loop
- Get post offset/posts page offset in single post page (outside the loop)
- How to modify search.php to not show pages only show posts
- First archive page with a few posts
- Tags on page (not post) returns nothing – why? Improved clarified question!
- Include future posts in tags and in search
- Exclude page from loop results
- Print the whole page?
- WP_Query is only looping home page, not pages
- Search page loop banner image issue
- Does search.php autofilter The Loop?
- How do i create a list-posts-page?
- WordPress: query pages except remove one page
- How do I set the Stewart Search Template to return only published posts in the result
- Trying to get all links in my posts
- Archive: Lists itself
- is it bad to copy the loop for a template?
- Get top Page IDs from menu and cycle through their child pages on a scroller
- Work arounds for conditional checks inside the loop in search.php?
- Structure and Display Content from Multiple Pages on Single Page
- Making a specific page wordpress compatable that is not index
- Default Template infinite loop of Title
- Have multiple loops on a page appear after/between page content
- get_template_part() to render single page Theme
- Eliminate duplicates in a foreach loop [closed]
- get_page() unlike Loop returns the post content without html tags. How can I fix this?
- How to check if I’m on the last page of posts?
- Retrieve each widget separately from a sidebar
- Where should I use post_class()?
- get_the_foo() in the loop – does it perform another query?
- Exclude filter on front page
- Check if date of post is yesterday
- Exclude first 2 posts with meta_key from loop
- Fix inefficient loop breaks post.php on form submit
- the_content() seems to block my ACF-code
- Pulling current post/page data into header.php
- Form action redirect to the same page
- Get single post from tags array
- Apply an Incremental Counter in an Array Function
- Get all posts including sticky ones with get_posts(),setup_postdata(), and foreach loop?
- Latest Post Styled Different Than other Posts
- Woocommerce: How to display product price [closed]
- Can I add generic numbering HTML classes to items as a loop runs?
- Add “showing posts x to x of y” in custom post type paginated loop
- Custom Post Type on Homepage – Studiopress Genesis Framework
- New loop vs widget
- Display a single category in blog section
- Yoast taking over my WordPress title tag [closed]
- Pagination broken after using 2 loops to show content
- Getting page slug
- How to get pagination to work with 2 wordpress loops
- How is WordPress changing the content markup?
- Custom Blog Loop on Home Page
- Exceprt not displaying
- Add File Attachment Name and URL into Javascript
- Show only pages you are author of
- Updating Post meta (ACF field) from Feed
- A code that I could not fully grasp related to foreach & count_user_posts()
- get_posts changes main query
- Archive sorted by month – separate
- Humanmade | Custom meta box class: How to display a repeatable meta box group?
- Can’t print out returned value
- Get query result before posts are displayed?
- WordPress Group By Problem
- Home page loop with pagination problem
- WooCommerce custom loop pagination on front page
- When and how will php code in a user made WordPress page be executed?
- Problem with ms-thumb-frame-selected class in Master Slider
- I want the first post on my home page to be lengthier than the rest (example included)
- Loop with Custom Post Type Taxonomies and Interstitial Code
- Question about custom plugin
- How can you make it so the comment box shows on some pages or posts but not all?
- Hook in the loop after the first post