Hi Wim!
I need to expand select field for parent and child terms
Here is an example what I need http://wimleers.com/demo/hierarchical-select/menu
I read README and found this:
Setting a fixed size
When you don't want users to be able to resize a hierarchical select
themselves, you can set a fixed size in advance yourself
Setting #size to >1 does *not* generate #multiple = TRUE selects! And the
opposite is also true. #multiple sets the "multiple" HTML attribute. This
enables the user to select multiple options of a select. #size just controls
the "size" HTML attribute. This increases the vertical size of selects,
thereby showing more options.Can you please clarify where is "#size" variable or how to create the variable? Hard to understand because I'm not a coder.
Thanks!
Comments
Comment #1
wim leersUse hook_form_alter() and set the #size attribute of the HS form item. I can't put *every* detail in the config UI, because it would become too cluttered. Very, very few users need this. Which is why you have to do this manually using FAPI. Sorry :)
Comment #3
iori57 commentedI have no idea how to use FAPI nor hook_form_alter() ... how to achieve this?
Comment #4
buckley commentedI also could use this (in the gui :) )
Comment #5
nodecode commentedI LOVE this module (really great work) but I third that emotion. I could TOTALLY use a select field size option in the UI and i bet there's more users than you think who need this too.
Not being able to see all of the terms on the list makes the selection process much harder to follow than the example you provide on your demo page. After i've resized the window like i want, EVERY time i click on an item or click the ADD button...*BAM* it snaps back to one line and i visually loose my place. I constantly have to resize the window making the resize feature frustrating rather than useful.
I also have no experience with templates or Forms API (though im reading up on it) so i can't figure out how I'm supposed to get this to work. As i said before i LOVE this module. I don't know, if you can't find time to put this in the UI, can you at least expand on the explanation quoted in the first post of this thread? maybe just a quick php example and we can figure out the rest.
Comment #6
wim leersComment #7
robby.smith commentedsubscribing
Comment #8
wim leersOh, it should not snap back to one line! That's definitely a bug.
I.e. the somewhat old 5.x-3.x-dev build that's running on my website does not have this bug: http://wimleers.com/demo/hierarchical-select/taxonomy.
Comment #9
triblondon commentedI also see this issue in 6.x production and dev releases.
Comment #10
wim leersOkay, I spent some time tracking down the cause of this bug and found it! :)
http://drupal.org/cvs?commit=412202