is_singular( string|array $post_types = '' )

Is the query for an existing single post of any post type (post, attachment, page, custom post types)?


25 related functions found for: is_singular

Top ↑

Related terms found for this post

TaxonomyTerms
wp-parser-related-wordsexist, is, query-php, singular, wp-includes
wp-parser-packageQuery, WordPress
wp-parser-source-filewp-includes/query.php

Top ↑

Terms Used Terms Used

Terms used in the related posts query

  • exist
  • is
  • Query
  • query-php
  • singular
  • wp-includes
  • wp-includes/query.php
  • query

Top ↑

Description Description

If the $post_types parameter is specified, this function will additionally check if the query is for one of the Posts Types specified.


Top ↑

Parameters Parameters

$post_types

(string|array) (Optional) Post type or array of post types.

Default value: ''


Top ↑

Return Return

(bool) Whether the query is for an existing single post of any of the given post types.


Top ↑

Source Source

File: wp-includes/query.php


			

Top ↑

Changelog Changelog

Changelog
Version Description
1.5.0 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

You must log in before being able to contribute a note or feedback.