Changeset 8618
- Timestamp:
- 04/10/2019 05:01:16 AM (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/wordpress.org/public_html/wp-content/plugins/support-forums/inc/class-hooks.php
r8465 r8618 95 95 add_filter( 'bbp_template_redirect', array( $this, 'disable_404_for_user_profile' ) ); 96 96 97 // Deindex Support Forum Feeds. bbPress hooks in way earlier than most Core feed functions.. 98 add_action( 'request', array( $this, 'deindex_forum_feeds' ), 5 ); 97 99 } 98 100 … … 859 861 } 860 862 } 863 864 /** 865 * Deindex Forum feeds. 866 * 867 * bbPress hooks in way earlier than most Core feed functions, so this is hooked to 'request' at priority 5. 868 */ 869 function deindex_forum_feeds( $query_vars ) { 870 if ( isset( $query_vars['feed'] ) ) { 871 header( 'X-Robots-Tag: noindex, follow' ); 872 } 873 874 return $query_vars; 875 } 861 876 }
Note: See TracChangeset
for help on using the changeset viewer.