Issue on passing a checkbox set to an AppEngine script through jQuery Ajax/Json -


i have set of checkboxes multiple choice allowed. parse set way:

if ($("input[name='route_day']:checked").length > 0) {     $("input[name='route_day']:checked").each(function(){      if(this.value != null)   route_days_hook.push(this.value);    });   datatrap.route_days = $.json.encode(route_days_hook); } 

...and pull whole datatrap appengine python script via jquery ajax. however, python script bugs. if change datatrap.route_days value string instead of json encoded object, works fine.
question is: how can pass checkbox set script using ajax , still able iterate on over script?

have tried:

 datatrap.route_days = $.parsejson(route_days_hook); 

edit

if didn't work, maybe it's because trying convert array object json...

try solution instead.


Comments

Popular posts from this blog

javascript - Enclosure Memory Copies -

php - Replacing tags in braces, even nested tags, with regex -