I am trying to use wp_dropdown_categories at front end. I got the dropdown box with default "uncategorized", the rest of the category is not there.
function cats_dropdown(){
require_once(ABSPATH . '/wp-admin/includes/template.php');
$args = array('taxonomy' => 'category');
?>
<div>
<?php wp_dropdown_categories($args); ?>
</div>
<?php
}
In the same function, if I try to output wp_terms_checklist, it works. This is confusing. Anything I missed in the dropdown?