Changeset 19304 for trunk/wp-includes/general-template.php
- Timestamp:
- 11/15/2011 08:44:48 PM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-includes/general-template.php
r19282 r19304 1678 1678 * 1679 1679 * If a blog is marked as not being public then the noindex meta tag will be 1680 * output to tell web robots not to index the page content. 1680 * output to tell web robots not to index the page content. Add this to the wp_head action. 1681 * Typical usage is as a wp_head callback. add_action( 'wp_head', 'noindex' ); 1682 * 1683 * @see wp_no_robots 1681 1684 * 1682 1685 * @since 2.1.0 … … 1685 1688 // If the blog is not public, tell robots to go away. 1686 1689 if ( '0' == get_option('blog_public') ) 1687 echo "<meta name='robots' content='noindex,nofollow' />\n"; 1690 wp_no_robots(); 1691 } 1692 1693 /** 1694 * Display a noindex meta tag. 1695 * 1696 * Outputs a noindex meta tag that tells web robots not to index the page content. 1697 * Typical usage is as a wp_head callback. add_action( 'wp_head', 'wp_no_robots' ); 1698 * 1699 * @since 3.3.0 1700 */ 1701 function wp_no_robots() { 1702 echo "<meta name='robots' content='noindex,nofollow' />\n"; 1688 1703 } 1689 1704
Note: See TracChangeset
for help on using the changeset viewer.