javascript - Uncaught TypeError: Cannot read property 'jQuery110102358926620800048' of undefined -



javascript - Uncaught TypeError: Cannot read property 'jQuery110102358926620800048' of undefined -

i store json object in html5 localstorage used generate number of different form fields.

$(document).on('click','.checklistobject', function(){ var allchecklists = json.parse(localstorage.checklists); var element_id = this.id; $.each(allchecklists,function(key,val){ if (val.id == element_id) { displaychecklist(val, undefined); } }); });

on first click on unordered list corresponds above, error in console:

uncaught typeerror: cannot read property 'jquery110102358926620800048' of undefined

however on sec click, works, , fires correctly. error said found in jquery.js see total traceback here "http://pastebin.com/rr9d6myx", refers 1 line in code, one:

$('#content-body').trigger('create');

which applies jquery mobile css-styling dynamically loaded content. thing points jquery mobile that, if load original unordered without jqmobile styling, error isn't present.

edit: below displaychecklist function:

function displaychecklist(checklistjson, previoussubmission){ var createform = $("#myform").dform(checklistjson); createform.promise().done(function(){ $('#content-body').trigger('create'); //apply jquery mobile styling $.mobile.navigate("#formpage"); //go form page if (previoussubmission == undefined) { //console.log("previoussubmission undefined!"); } else { repopulateform(previoussubmission); } }); };

javascript jquery html5 jquery-mobile

Comments

Popular posts from this blog

c# - ASP.NET MVC Sequence contains no matching element -

java - Parsing XML, skip certain tags -

rest - How to invalidate user session on inactivity in a stateless server? -