• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 164
  • Last Modified:

Converting a drop down list into Bootstrap

Hi
I have the following DDL:
<ul id="buttons">
      <label for="activities">Activity</label>      
      <select id="activities" onChange="setMarkers();">
        <option value="venues">Venues</option>
        <option value="bikes">Bikes</option>        
        <option value="all" selected="selected">show all</option>
      </select>
      <label for="prices">Prices</label>  
      <select id="prices" onChange="setMarkers();">
        <option value="0">0</option>
        <option value="< 5">< 5</option>
        <option value="> 5">> 5</option>
        <option value="< 10">< 10</option>
        <option value="> 10">> 10</option>
        <option value="all" selected="selected">show all</option>
      </select>
   </ul> 

Open in new window


I want to make this look good by using the bootstrap framework but I haven't been able to find any information on how I can build a drop down list with HTML that will do the same as the above... adding value="" doesn't appear to work!

thanks
0
lz7cjc
Asked:
lz7cjc
1 Solution
 
lenamtlCommented:
Hi,
See the Bootstrap documentation about dropdown:
http://getbootstrap.com/components/#btn-dropdowns
and this require the javascript http://getbootstrap.com/javascript/#dropdowns

Here is an few example: http://bootsnipp.com/snippets/featured/button-dropdown-select

you can use data-value="myvalue"
0
 
Tom BeckCommented:
A jsfiddle sample using your list. I included an example of how you might capture selections.

http://jsfiddle.net/tommyBoy/zxjnL990/
0
 
lz7cjcAuthor Commented:
fantastic - thanks v much
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now