SHARE
TWEET

Untitled

a guest Jun 25th, 2019 69 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. function insert_term( $name,$tax,$parent='' ,$slug='') {
  2.     $term_id = term_exists( $name, $tax);
  3.     if ( !$term_id)
  4.         $term_id = wp_insert_term( $name, $tax, array('parent'=>$parent,'slug'=>$ludg) );
  5.     return $term_id;
  6. }
  7.  
  8. insert_term('USSERS','category');
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Not a member of Pastebin yet?
Sign Up, it unlocks many cool features!
 
Top