Create New Page On Same Page

[Total: 0    Average: 0/5]

This shows how to have javascript generate a new page on the same page.

Body Code:

This is page 1.<BR><a href="javascript:go2()">Click to generate page 2</a>
<script>
function go2()
{
  var _a = "<html><head><title>page2</title><body>This is page 2.</body></html>";
  document.open();
  document.write(_a);
  document.close();
}
</script>

Times Viewed: 0

Leave a Reply

Your email address will not be published. Required fields are marked *