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
156                          'name'             => 'parent',
157                          'orderby'          => 'name',
158                          'selected'         => $tag->parent,
159                          'exclude_tree'     => $tag->term_id,
160                          'hierarchical'     => true,
161                          'show_option_none' => __( 'None' ),
162                     );
163
164                     /** This filter is documented in wp-admin/edit-tags.php */
165                     $dropdown_args = apply_filters( 'taxonomy_parent_dropdown_args', $dropdown_args, $taxonomy, 'edit' );
166                     wp_dropdown_categories( $dropdown_args ); ?>
167                     <?php if ( 'category' == $taxonomy ) : ?>
168                          <p class="description"><?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>
169                     <?php else : ?>
170                          <p class="description"><?php _e( 'Assign a parent term to create a hierarchy. The term Jazz, for example, would be the parent of Bebop and Big Band.' ); ?></p>
171                     <?php endif; ?>
172                </td>
173           </tr>
174 <?php endif; // is_taxonomy_hierarchical() ?>