Enable more flexibility for non-URL GUIDs.
props stevenkword. fixes #31080. git-svn-id: https://develop.svn.wordpress.org/trunk@31726 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
2c9a5e3b8b
commit
8f9bef790e
@ -167,6 +167,7 @@ add_filter( 'comment_text_rss', 'ent2ncr', 8 );
|
||||
add_filter( 'comment_text_rss', 'esc_html' );
|
||||
add_filter( 'bloginfo_rss', 'ent2ncr', 8 );
|
||||
add_filter( 'the_author', 'ent2ncr', 8 );
|
||||
add_filter( 'the_guid', 'esc_url' );
|
||||
|
||||
// Misc filters
|
||||
add_filter( 'option_ping_sites', 'privacy_ping_filter' );
|
||||
|
@ -172,7 +172,14 @@ function get_the_title( $post = 0 ) {
|
||||
* @param int|WP_Post $id Optional. Post ID or post object.
|
||||
*/
|
||||
function the_guid( $id = 0 ) {
|
||||
echo esc_url( get_the_guid( $id ) );
|
||||
/**
|
||||
* Filter the escaped Global Unique Identifier (guid) of the post.
|
||||
*
|
||||
* @since 4.2.0
|
||||
*
|
||||
* @param string $post_guid Escaped Global Unique Identifier (guid) of the post.
|
||||
*/
|
||||
echo apply_filters( 'the_guid', get_the_guid( $id ) );
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user