Filters the permalink structure for a post before token replacement occurs. Only applies to posts with post_type of 'post'.
$permalink, $post, $leavename
Sortie :
@param string $permalink The site's permalink structure. @param WP_Post $post The post in question. @param bool $leavename Whether to keep the post name.
// Modifier la valeur avec le filtre 'pre_post_link'
add_filter('pre_post_link', 'ma_fonction_filtre', 10, 1);
function ma_fonction_filtre($permalink) {
// Modifier la valeur
return $permalink;
}
Chargement des actualités...