Menu Adam R Brown

WP hooks navigation: Home/browseActions indexFilters index

Source View: taxonomy_parent_dropdown_args

To save our bandwidth, we show only a snippet of code around each occurence of the hook. View complete file in SVN (without highlighting).

Understanding Source Code

The best way to understand what a hook does is to look at where it occurs in the source code.

Remember, this hook may occur in more than one file. Moreover, the hook's context may change from version to version.

Source View

Line Code
487       *     @type string   $taxonomy         The taxonomy slug.
488       *     @type string   $name             Value of the name attribute to use for the drop-down select element.
489       *                                      Default 'parent'.
490       *     @type string   $orderby          The field to order by. Default 'name'.
491       *     @type bool     $hierarchical     Whether the taxonomy is hierarchical. Default true.
492       *     @type string   $show_option_none Label to display if there are no terms. Default 'None'.
493       * }
494       * @param string $taxonomy The taxonomy slug.
495       */
496      $dropdown_args = apply_filters( 'taxonomy_parent_dropdown_args', $dropdown_args, $taxonomy );
497      wp_dropdown_categories( $dropdown_args );
498      ?>
499      <?php if ( 'category' == $taxonomy ) : // @todo: Generic text for hierarchical taxonomies ?>
500           <p><?php _e('Categories, unlike tags, can have a hierarchy. You might have a Jazz category, and under that have children categories for Bebop and Big Band. Totally optional.'); ?></p>
501      <?php endif; ?>
502 </div>
503 <?php endif; // is_taxonomy_hierarchical() ?>
504 <div class="form-field term-description-wrap">
505      <label for="tag-description"><?php _e( 'Description' ); ?></label>