[ Index ] |
PHP Cross Reference of WordPress |
[Source view] [Print] [Project Stats]
Robots template functions.
File Size: | 193 lines (5 kb) |
Included or required: | 0 times |
Referenced: | 0 times |
Includes or requires: | 0 files |
wp_robots() X-Ref |
Displays the robots meta tag as necessary. Gathers robots directives to include for the current context, using the {@see 'wp_robots'} filter. The directives are then sanitized, and the robots meta tag is output if there is at least one relevant directive. since: 5.7.0 since: 5.7.1 No longer prevents specific directives to occur together. |
wp_robots_noindex( array $robots ) X-Ref |
Adds `noindex` to the robots meta tag if required by the site configuration. If a blog is marked as not being public then noindex will be output to tell web robots not to index the page content. Add this to the {@see 'wp_robots'} filter. Typical usage is as a {@see 'wp_robots'} callback: add_filter( 'wp_robots', 'wp_robots_noindex' ); return: array Filtered robots directives. since: 5.7.0 param: array $robots Associative array of robots directives. |
wp_robots_noindex_embeds( array $robots ) X-Ref |
Adds `noindex` to the robots meta tag for embeds. Typical usage is as a {@see 'wp_robots'} callback: add_filter( 'wp_robots', 'wp_robots_noindex_embeds' ); return: array Filtered robots directives. since: 5.7.0 param: array $robots Associative array of robots directives. |
wp_robots_noindex_search( array $robots ) X-Ref |
Adds `noindex` to the robots meta tag if a search is being performed. If a search is being performed then noindex will be output to tell web robots not to index the page content. Add this to the {@see 'wp_robots'} filter. Typical usage is as a {@see 'wp_robots'} callback: add_filter( 'wp_robots', 'wp_robots_noindex_search' ); return: array Filtered robots directives. since: 5.7.0 param: array $robots Associative array of robots directives. |
wp_robots_no_robots( array $robots ) X-Ref |
Adds `noindex` to the robots meta tag. This directive tells web robots not to index the page content. Typical usage is as a {@see 'wp_robots'} callback: add_filter( 'wp_robots', 'wp_robots_no_robots' ); return: array Filtered robots directives. since: 5.7.0 param: array $robots Associative array of robots directives. |
wp_robots_sensitive_page( array $robots ) X-Ref |
Adds `noindex` and `noarchive` to the robots meta tag. This directive tells web robots not to index or archive the page content and is recommended to be used for sensitive pages. Typical usage is as a {@see 'wp_robots'} callback: add_filter( 'wp_robots', 'wp_robots_sensitive_page' ); return: array Filtered robots directives. since: 5.7.0 param: array $robots Associative array of robots directives. |
wp_robots_max_image_preview_large( array $robots ) X-Ref |
Adds `max-image-preview:large` to the robots meta tag. This directive tells web robots that large image previews are allowed to be displayed, e.g. in search engines, unless the blog is marked as not being public. Typical usage is as a {@see 'wp_robots'} callback: add_filter( 'wp_robots', 'wp_robots_max_image_preview_large' ); return: array Filtered robots directives. since: 5.7.0 param: array $robots Associative array of robots directives. |
Generated: Tue Dec 24 01:00:02 2024 | Cross-referenced by PHPXref 0.7.1 |