[Resolved] Limit number of options visible in search dropdown box (taxonomy) & scroll list
This support ticket is created 5 years, 5 months ago. There's a good chance that you are reading advice that it now obsolete.
This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.
Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.
No supporters are available to work today on Toolset forum. Feel free to create tickets and we will handle it as soon as we are online. Thank you for your understanding.
I have a view that allows users to search for listings by location (taxonomy). The list is large so I only want the dropdown box to show 4 options at a time but allow the user to scroll through all available choices (or type "F" to jump to "FL-Orlando"
<select name="select1" onmousedown="if(this.options.length>3){this.size=3;}" onchange='this.size=0;' onblur="this.size=0;">
<option value="1">This is select number 1</option>
<option value="2">This is select number 2</option>
<option value="3">This is select number 3</option>
<option value="4">This is select number 4</option>
<option value="5">This is select number 5</option>
<option value="6">This is select number 6</option>
<option value="7">This is select number 7</option>
<option value="8">This is select number 8</option>
<option value="9">This is select number 9</option>
<option value="10">This is select number 10</option>
<option value="11">This is select number 11</option>
<option value="12">This is select number 12</option>
</select>
The code works and renders what I want with the dummy information listed. I can't find a way to fit:
[wpv-control-post-taxonomy taxonomy="market" type="select" url_param="wpv-market"]
into the code so that it picks up my taxonomy values (NY-Buffalo)
That definitely limits the vertical size of the box but it stays "open" with 10 options visible after a selection is made (see pic). How do I reduce the box back to its original size (1 line) after a selection is made?
Thanks!! This is so much better than what it was showing before!