Trying to post current webpage with jQuery to another page
Is it possible to post the entire webpage to another page? I'm trying to post the entire Dom starting with the html tag and ending with the endi开发者_StackOverflowng html tag to another web page. I want to then save that web page with a date time stamp using asp or asp.net. If I can't simply post it is it possible to use ajax to post it?
document.documentElement.innerHTML
Contains everything between the opening and closing HTML tags. But does not include the HTML tags themselves.
You can use the jQuery.ajax method to post that value to your script. That method would require the script to be on the same domain as the page you are calling it from of course.
精彩评论