Changeset 9503 for sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-developer/inc/template-tags.php
- Timestamp:
- 02/13/2020 11:40:22 PM (5 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
r9325 r9503 1682 1682 1683 1683 // Get explanation's raw post content. 1684 $content = get_explanation_field( 'post_content', $_post ); 1684 $content = ''; 1685 if ( 1686 ! empty( $_GET['wporg_explanations_preview_nonce'] ) 1687 && 1688 false !== wp_verify_nonce( $_GET['wporg_explanations_preview_nonce'], 'post_preview_' . $post->ID ) 1689 ) { 1690 $preview = wp_get_post_autosave( $post->ID ); 1691 1692 if ( is_object( $preview ) ) { 1693 $post = $preview; 1694 $content = get_post_field( 'post_content', $preview, 'display' ); 1695 } 1696 } else { 1697 $content = get_explanation_field( 'post_content', $_post ); 1698 } 1685 1699 1686 1700 // Pass the content through expected content filters.
Note: See TracChangeset
for help on using the changeset viewer.