Switch language

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




wp_set_post_tags [ WordPress Function ]

wp_set_post_tags ( $post_id = 0, $tags = '', $append = false )
Parameters:
  • (int) $post_id Post ID.
  • (string) $tags The tags to set for the post, separated by commas.
  • (bool) $append If true, don't delete existing tags, just add on. If false, replace the tags with the new tags.
Uses:
Returns:
  • (mixed) Array of affected term IDs. WP_Error or false on failure.
Defined at:



Set the tags for a post.

Source


<?php
function wp_set_post_tags$post_id 0$tags ''$append false ) {
    return 
wp_set_post_terms$post_id$tags'post_tag'$append);
}
?>

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