Reputation: 177
I want to have a Hierarchical Data in select box with php:
But when I use optgroup, the <optgroup>
couldnt have a value.
Is there any way to have a Hierarchical Data like this image?
Thanks in advance
Upvotes: 0
Views: 784
Reputation: 48387
You've tagged this as php but it's not anything to do with PHP.
Optgroups don't have values - they have labels.
You might want to checkout phplm
Upvotes: 0
Reputation: 14951
Optgroup isn't selectable either.
I always use indenting with
to create an hierarchical select box.
Upvotes: 1