Changeset 1269 for sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-developer/inc/template-tags.php
- Timestamp:
- 02/17/2015 07:37:27 PM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-developer/inc/template-tags.php
r1196 r1269 784 784 785 785 /** 786 * Indicates if a post is deprecated. 787 * 788 * @param int $post_id 789 * 790 * @return bool 791 */ 792 function is_deprecated( $post_id = null ) { 793 if ( empty( $post_id ) ) { 794 $post_id = get_the_ID(); 795 } 796 797 $tags = get_post_meta( $post_id, '_wp-parser_tags', true ); 798 $all_deprecated = wp_filter_object_list( $tags, array( 'name' => 'deprecated' ) ); 799 800 return !! $all_deprecated; 801 } 802 803 /** 786 804 * Retrieve deprecated flag 787 805 *
Note:
See TracChangeset
for help on using the changeset viewer.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)