the_shortlink ( $text = '', $title = '', $before = '', $after = '' )

  • (string) $text Optional The link text or HTML to be displayed. Defaults to 'This is the short link.'
  • (string) $title Optional The tooltip for the link. Must be sanitized. Defaults to the sanitized post title.
  • (string) $before Optional HTML to display before the link. Default empty.
  • (string) $after Optional HTML to display after the link. Default empty.
Defined at:


Displays the shortlink for a post.

Must be called from inside "The Loop"

Call like the_shortlink( __( 'Shortlinkage FTW' ) )

Related Functions

the_author_link, wp_get_shortlink, get_shortcut_link, the_author_posts_link, the_permalink

Top Google Results

User discussions

wpseek mobile