Tuesday, April 2, 2019

jquery is unable to set the prettyCheckable plugin radio button programmatically

I am using the prettyCheckable jquery plugin to make my checkboxes and radio buttons look pretty and if I use jquery to set the property checked it does not work because the plugin hides the actual checkbox and makes it's own override HTML to pretty up the checkbox/radio, therefore the jquery doesn't recognize when I check the radio or checkbox



//on button click I tried all the things, but nothing is working. please help




    



$('#rdTypeAdd').buttonset();
$('[name="rdTypeAdd"][value="+"]').prop("checked", true);
$('#rdTypeAdd').buttonset("refresh");

//$('[name="rdTypeAdd"][value="+"]').attr("checked", true);
//$('[name="rdTypeAdd"][value="+"]').prop("checked", true).trigger("change");


//($('.rdTypeAdd').prop('checked',true));

No comments:

Post a Comment

plot explanation - Why did Peaches' mom hang on the tree? - Movies & TV

In the middle of the movie Ice Age: Continental Drift Peaches' mom asked Peaches to go to sleep. Then, she hung on the tree. This parti...