• Hey Guys,

    I’m working with the following code (via this link, http://codex.wordpress.org/Template_Tags/wp_dropdown_categories) to display all my category listings in a dropdown menu. The code looks like this:

    <form action="<?php bloginfo('url'); ?>/" method="get">
    		<?php
    			$select = wp_dropdown_categories('show_option_none=Select Category&show_count=1&orderby=name&echo=0&hide_empty=0');
    			$select = preg_replace("#<select([^>]*)>#", "<select$1 onchange='return this.form.submit()'>", $select);
    			echo $select;
    		?>
    		<noscript><input type="submit" value="View" /></noscript>
    		</form>

    However the problem I’m having is that by default, one of my other categories always shows up first, rather than “Select Category”, as it should be.

    Is there something obvious I’m missing here?

    Any advice would be appreciated.

    Thanks.

Viewing 6 replies - 1 through 6 (of 6 total)
Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Category Drop Down – Minor Bug/Issue’ is closed to new replies.