Posts

Showing posts with the label Placeholder

Bootstrap Select Dropdown List Placeholder

Answer : Yes just "selected disabled" in the option. <select> <option value="" selected disabled>Please select</option> <option value="">A</option> <option value="">B</option> <option value="">C</option> </select> Link to fiddle You can also view the answer at https://stackoverflow.com/a/5859221/1225125 Use hidden: <select> <option hidden >Display but don't show in list</option> <option> text 1 </option> <option> text 2 </option> <option> text 3 </option> </select> dropdown or select doesn't have a placeholder because HTML doesn't support it but it's possible to create same effect so it looks the same as other inputs placeholder $('select').change(function() { if ($(this).children('option:first-child').is(':selected')) ...