Docs: Document the $post global in comment feed templates.

Follow-up to [18716].

Props viralsampat, sabernhardt.
See #60021.
Built from https://develop.svn.wordpress.org/trunk@57759


git-svn-id: http://core.svn.wordpress.org/trunk@57260 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Sergey Biryukov 2024-03-04 12:41:10 +00:00
parent 68f21dbbb6
commit 3dc3dc25e9
3 changed files with 9 additions and 3 deletions

View File

@ -69,7 +69,10 @@ do_action( 'rss_tag_pre', 'atom-comments' );
<?php
while ( have_comments() ) :
the_comment();
$comment_post = get_post( $comment->comment_post_ID );
$comment_post = get_post( $comment->comment_post_ID );
/**
* @global WP_Post $post Global post object.
*/
$GLOBALS['post'] = $comment_post;
?>
<entry>

View File

@ -72,7 +72,10 @@ do_action( 'rss_tag_pre', 'rss2-comments' );
while ( have_comments() ) :
the_comment();
$comment_post = get_post( $comment->comment_post_ID );
$comment_post = get_post( $comment->comment_post_ID );
/**
* @global WP_Post $post Global post object.
*/
$GLOBALS['post'] = $comment_post;
?>
<item>

View File

@ -16,7 +16,7 @@
*
* @global string $wp_version
*/
$wp_version = '6.5-beta3-57758';
$wp_version = '6.5-beta3-57759';
/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.