wp code snippet

WordPress, PHP quick help codes

How to fix loosing hierarchy of Hierarchical Taxonomies in WordPress?

While editing the post, the tree structure of the taxonomy seems to be lost. Here is the code that will fix loosing hierarchy of Hierarchical Taxonomies.

function taxonomy_checklist_checked_ontop_filter ($args) {
$args['checked_ontop'] = false;
return $args;
}

add_filter('wp_terms_checklist_args','taxonomy_checklist_checked_ontop_filter');

Categories: WordPress

Leave a Reply

%d bloggers like this: