jquery - Dynamically loaded javascripts adding extra quotes for object values -
i loading javascript object dynamically injecting script.
(function (jql) { jql.addresource({ reskey1:'js english res', reskey2:'js english res2', }); })(jquerylocalization); i filling object jquery custom plugin variable using below script -
$.each(data, function (key, value) { // global variable store key values dictionary jql.resources[key] = value; // printing value without quotes - 'js english res' alert("val " + jql.resources[key]); }); outside block when trying access values adds quotes, comma value. see console logs.

when accessed object in console, shows values quotes , comma.
did faced such issues? suggestion doing wrong.
there issue internal condition failing outside $.each(). that's why working inside $.each() , not outside.
Comments
Post a Comment