when my html elements are stored in variable then how can i access any html element from the variable. suppose if i need to extract or manipulate div called "dv1" or dv2. may be i may need to insert row in table mytab. then how can i do it? please help me with sample code.
$("#btnPrint").click(function () {
sHtml = "<div id='dv1'><table id='mytab'>";
sHtml += "<tr><td>" + "<img src='" + ImgPath + "' border='0'/>" + "</td></tr>";
sHtml += "<tr><td>" + $('#lblTxt').html() + "</td></tr>";
sHtml += "</table><div id='dv2'>my content here</div></div>";
return false;
});
thanks