Switch language

wpseek.com
A WordPress-centric search engine for devs and theme authors




wp_shortlink_header [ WordPress Function ]

wp_shortlink_header ( No parameters )
Uses:
Defined at:



Send a Link: rel=shortlink header if a shortlink is defined for the current page.

Attached to the wp action.

Source


<?php
function wp_shortlink_header() {
    if ( 
headers_sent() )
        return;

    
$shortlink wp_get_shortlink(0'query');

    if ( empty(
$shortlink) )
        return;

    
header('Link: <' $shortlink '>; rel=shortlink'false);
}
?>

Examples [ wp-snippets.com ]

Top Google zoekresultaten

Meer ...

Gebruikersdiscussies [ wordpress.org ]

0 User Note(s)

Nog geen één. Wees de eerste!

Nieuw toevoegen ...



HTML5 Powered with CSS3 / Styling, Performance & Integration, and Semantics