wp-includes/post-template.php:221Retrieves the Post Global Unique Identifier (guid).
$postint|WP_Postoptional0stringOne hook fires while get_the_guid() runs, in this order:
Filters the Global Unique Identifier (guid) of the post.
function get_the_guid( $post = 0 ) { $post = get_post( $post ); $post_guid = $post->guid ?? ''; $post_id = $post->ID ?? 0; /** * Filters the Global Unique Identifier (guid) of the post. * * @since 1.5.0 * * @param string $post_guid Global Unique Identifier (guid) of the post. * @param int $post_id The post ID. */ return apply_filters( 'get_the_guid', $post_guid, $post_id );}Introduced in 1.5.0. Unchanged from 6.7.7 through 7.1.0.
Signature, return type and hooks compared across 5 parsed releases.
src/wp-includes/post-template.php, and regenerated for each WordPress release so it tracks the code rather than a snapshot of it.