I've got an object like this:
var obj = {
age:["23"],
part:["0"],
race:[],
state:["AL"],
gender:["1"],
county:["9999"],
consent:["9999"]
};
I pass this object to php for processing, but race[] is not passed to php along with everything else. How do I change race so it gets sent and has a value of ""?
EDIT: Any one of those (age, part, race, …) could be empty, so I need a way to check and then change.
I've used this code to loop thru the object/array: http://jsfiddle.net/jshado1/wLZMH/
obj.race = [""];?race:["asian","black","white"]