WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am unable to get the Parent Taxonomy Terms here is the code i am writing

$myterms = get_terms( 'iqvis_event_category', array( 'parent' => 0 ) );
echo '<pre>'; 
echo '</pre>';

What is the Reason is there any Syntax problem ? or the parent argument is not working?? because if i am not giving the parent argument its working and getting all the terms with their children.

share|improve this question
i don't see any problem with it. there's no syntax problem. include your results – peteroak Aug 8 '12 at 10:47
its nothing all i have to do add another argument 'hide_empty' => 0 then it was returning everything – PhpSeeker Aug 8 '12 at 10:50
@PhpSeeker if that solved your problem, add it as an answer – Joseph Leedy Aug 8 '12 at 13:56
Added Already Joseph :) – PhpSeeker Aug 9 '12 at 3:57
up vote 1 down vote accepted

I figured it out I just have to add another argument and then it was working fine:

$myterms = get_terms( 'iqvis_event_category', array( 'parent' => 0, 'hide_empty' => 0 ) );
echo '<pre>'; 
echo '</pre>';
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.