pakbull6772540
Posts: 0
Joined: Sun Mar 30, 2014 4:08 pm

javascript to change the color of the check boxes

I will need to update the color of the radio group(multi-color). Does this code work?

Appery('rdogrp').find("input").each(function() {
// $(this).addClass('riskRed');
// alert($(this).id);
// $(this).css({backgroundColor: '#E7F009'});
// Appery('rdotbn_6').css('font-size', 'x-small');
$(this).next('label').children('span').css('background-color', 'red');
$(this).checkboxradio("refresh");
});

I have tried all this, including adding a "background-color" "red" property for the 'more properties' area of each item of the 9 item radio group. No luck.

Igor
Posts: 0
Joined: Tue Apr 02, 2013 12:05 pm

javascript to change the color of the check boxes

Hello,

Here is right code to change background of the radio buttons.

pre
code
//Get radioGroup component. You should use your component right name instead of "mobileradiogroup_15"
var radioGroup = Appery("mobileradiogroup_15");

//Get radioButtons components.
var radioButtons = radioGroup.find(".ui-btn");

for(var i = 0; i < radioButtons&#46;length; i++){
&#47;&#47;Change background color for each button&#46;
jQuery(radioButtons)&#46;css({background: "#ff0"});
};
/code
/pre

Return to “Issues”