[wp-hackers] wp_dropdown_categories and multiple selections
wp-hackers at google-adsense-templates.co.uk
Sun Mar 4 01:50:16 UTC 2012
On Sat, 3 Mar 2012 11:48:13 -0700, you wrote:
>> Maybe a better question would have been how to generate a comma
>> seperated list of categories for the $only variable without the user
>> typing them out as 3,8,123 since wp_dropdown_categories doesn't have
>> that as a feature :-)
>> Any ideas?
>There's a ticket on the track discussing this very topic:
>In your case, I'd echo scribu's sentiment and ask why not just provide a
>list of checkboxes as is done with the Categories metabox? UX for a
>multiple-select dropdown is awful.
Just figured it out, used code from this plugin
http://wordpress.org/extend/plugins/widgets-reloaded/ which includes a
multiple selection categories form within the widget-categories.php
I'm not a programmer (really struggle with PHP) and considered
multiple checkboxes, but sites with a lot of categories would be a
mess to fit in a widget. The solution I used I've limited the box to 6
items with a scroller so it's a simple hold CTRL and click the
categories I want to select.
I looked at around a dozen popular, recent and similar widget plugins
for ideas to solve this problem before finding Widgets Reloaded and
they ALL lack the ability to select exactly which cateogries to use,
the better ones tend to have the ability to use only one category or
exclude only one cateogry.
Seems a lack of a useful feature not to have a WordPress function like
wp_dropdown_categories that would allow for easy multiple selections,
seems a lot of widgets could benefit from this functionality. I agree
adding multiple selection to an actual dropdown form would be awful,
they are designed for single selection.
http://www.stallion-theme.com/ Stallion WordPress SEO Theme
WordPress SEO Plugin
>wp-hackers mailing list
>wp-hackers at lists.automattic.com
More information about the wp-hackers