I have a small problem with this array.
I need to add css class in each key has a value 0 for exemple, this is my essay:
var obj = {"test_1":"1","test_2":"1","test_3":"0","test_4":"0","test_5":"0","test_6":"1","test_7":"0"};
$.each( obj, function( key, value ) {
alert("key " + key + " has value " + obj[key]);
if(value = 0) {
$('#'+ key).addClass('hidden');// hidden only the obj has value = 0
}
});
==instead of=in your test condition for value