Uses
Uses | Description |
---|---|
wp-includes/link-template.php: get_permalink() | Retrieves the full permalink for the current post or post ID. |
Retrieves the full permalink for the current post or post ID.
This function is an alias for get_permalink().
(int|WP_Post) (Optional) Post ID or post object. Default is the global $post
.
(bool) (Optional) Whether to keep post name or page name.
Default value: false
(string|false) The permalink URL or false if post does not exist.
File: wp-includes/link-template.php
function get_the_permalink( $post = 0, $leavename = false ) { return get_permalink( $post, $leavename ); }
Version | Description |
---|---|
3.9.0 | Introduced. |
© 2003–2019 WordPress Foundation
Licensed under the GNU GPLv2+ License.
https://developer.wordpress.org/reference/functions/get_the_permalink