jquery - list appending to last element of collapsible set -
i tying create dynamic collapsible set , each set adding dynamic listview.
here how doing it:
function querysuccess(tx, results) { $.each(results.rows,function(index){ var row = results.rows.item(index); var list=$('#list').append('<li><h3 class="ui-li-heading">'+'</h3><p class="ui-li-">'+row['data']+'</p></li>'); var div = '<div data-role="collapsible" data-inset="false" data-iconpos="right"><h3>'+row["data"]+'</h3></div>'; $(list).appendto(div).parent().appendto('[data-role="content"]').end().trigger("create"); $('div[data-role=collapsible]').collapsible({theme:'c',refresh:true}); }); }
but dynamic listview appending last collapsible element , not able append others. mistake making?
Comments
Post a Comment