[Solved] Display checkbox after select combo box


Give your select list an ID.

Using jQuery:

$(document).ready(function(){
  $("#mySelect").change(function(){
    var selectValue = $("#mySelect").val();
    switch(selectValue){
      case "someValue":
        var checkbox = '<input type="checkbox" name="something" value="something" />'
        $("#someDiv").append(checkbox);
        break;
      case "someOtherValue":
        var checkbox = '<input type="checkbox" name="something" value="something" />'
        $("#someDiv").append(checkbox);
        break;
    }
  });
});

And so on. Hopefully, you get the idea.

5

solved Display checkbox after select combo box