Sponsored Link
PHPで使用するための投稿にショートリンクを返します。それはショートリンクを表示しません。
Returns the Short Link to a post for use in PHP. It does NOT display the short link.
Sponsored Link
wp_get_shortlinkのテンプレートタグ使用方法
<?php wp_get_shortlink(); ?>
例
プレインテキストにショートリンクを表示します。
Display the short link in plain text.
Short URL: http://example.com/?p=1234
Short URL:<?php echo wp_get_shortlink(); ?>
ソースファイル
wp_get_shortlink()は、wp-includes/link-template.php内に位置しています。
wp_get_shortlink() is located in wp-includes/link-template.php.