Changeset 8044 for sites/trunk/wordpress.org/public_html/wp-content/plugins/wporg-bbp-topic-archive/wporg-bbp-topic-archive.php
- Timestamp:
- 01/08/2019 06:21:37 AM (6 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/wordpress.org/public_html/wp-content/plugins/wporg-bbp-topic-archive/wporg-bbp-topic-archive.php
r3667 r8044 2 2 /** 3 3 * Plugin Name: bbPress: Topic Archive 4 * Description: Add noindex, nofollow to old topics.4 * Description: Add noindex,follow to old topics and closed topics without responses. 5 5 * Version: 1.0 6 6 * Author: WordPress.org … … 42 42 bbp_is_topic( $post->ID ) 43 43 && 44 ( time() - get_post_time( 'U', true, $post ) > YEAR_IN_SECONDS ) 44 ( 45 // Thread last modified is over a year old 46 ( time() - get_post_time( 'U', true, $post ) > YEAR_IN_SECONDS ) 47 || 48 // Closed thread with no replies 49 ( bbp_is_topic_closed( $post->ID ) && ! bbp_get_topic_reply_count( $post->ID, true ) ) 50 ) 45 51 ) { 46 echo '<meta name="robots" content="noindex, nofollow" />' . "\n";52 echo '<meta name="robots" content="noindex,follow" />' . "\n"; 47 53 } 48 54 }
Note: See TracChangeset
for help on using the changeset viewer.