Saving Dynamic Page
Hi..Friends.. Am in confusion to creating html page.
I have a 2 fields in my form and I have added another text box by clicking add button.
Text Box appears. Now totally 3 fields are there in a form..
And Now I need to save this page with 3 fields as Reg.html
How can I do it??????????????
Anybody Plz help me out!!!!!!
Browser "view source" or "save web page" does not preserve dynamically created DOM objects. For that use below given function, which will open a new window with all the source code including dynamically created DOM objects -
var win = window.open('','_blank');
var results = document.documentElement.innerHTML;
var match = "<";
var re = new RegExp("<", "g");
var newresults = results.replace(re, "<");
win.document.write('<pre>' +newresults+'</pre>' );