Answers for "open select dropdown"

0

open select dropdown

$('#MyButton').on("click",function(){
    $("#selecttest").attr("size", 8);
    $("#selecttest").css("position","fixed");
    $('#MyButton').css("margin-left", $("#selecttest").width() + 5);});
$('#selecttest').on("change",function(){
    $("#selecttest").attr("size", 1);});
Posted by: Guest on June-22-2020
0

open select dropdown

var myDropDown=$("#myDropDown");
var length = $('#myDropDown> option').length;
//open dropdown
myDropDown.attr('size',length);
Posted by: Guest on June-22-2020

Browse Popular Code Answers by Language