php - Get the_terms names for current post id -



php - Get the_terms names for current post id -

this work me when want array includes names of taxonomy:

get_terms( 'portfolio-skills', array( 'fields' => 'names' ) );

what if want terms names associated current post. tried it's not working:

get_terms( 'portfolio-skills', array( 'fields' => 'names' ), 'include' => array( $post->id ) );

thank @pekka 웃, alter , it's working:

wp_get_object_terms( $post->id, 'portfolio-skills', array( 'fields' => 'names' ) );

php wordpress custom-taxonomy

Comments

Popular posts from this blog

web services - java.lang.NoClassDefFoundError: Could not initialize class net.sf.cglib.proxy.Enhancer -

Accessing MATLAB's unicode strings from C -

javascript - mongodb won't find my schema method in nested container -