Questions and discussion about developing processes and programming in PHP, JavaScript, web services & REST API.

Moderators: ArturoRobles, ArturoRobles

Forum rules: Please search to see if a question has already asked before creating a new topic. Please don't post the same question in multiple forums.
User avatar
By amosbatto
#825434
Here is an example:
Code: Select all
$("#selectColor").setOnchange( function(newVal, oldVal) {
   if (newVal == "blue") {
       //first enable all radio options:
       $("#selectFurniture").find("input.pmdynaform-control-radio").prop("disabled", false);
       //then disable one of the radio options:
       $("#selectFurniture").find("input.pmdynaform-control-radio[value=chair]").prop("disabled", true);
       //if "chair" is the selected option, then unset the value in the radio box:
       if ($("selectFurniture").getValue() == "chair") {
           $("selectFurniture").setValue(""); //set to the first available option which isn't "chair"
       }
    }
});
Where selectColor is the ID of the dropdown box and if its selected option is "blue", then disable the option "chair" in the "selectFurniture" dropdown box.

Hi, I have around 100 variables in master process […]

Install in ubuntu

Nov 8, 2014 — You can install applications d[…]

Hi, The form.setOnchange() method does NOT work w[…]

design

Hi, You can easily change your forms like this eve[…]