Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
I'm not sure if you can specify more than one output. If you could, then you can create your file and send the html to the browser. If not, create the file, change STDOUT again, then read the file and send it to the browser. My javascript is weak, so I stick with what I know. I hope this helps.Re-opening STDOUT
It is quite permissible to re-open existing filehandles. When you do, the filehandle is first closed, and the new one is opened. This works with STDOUT too. You can re-open STDOUT, and then use the print statement to write to your new file by default.
open STDOUT, ">output.txt";
print "The quick brown fox\n";
close STDOUT;