I would like to know how to convert HTML code that users input into a
TEXTAREA box on a HTML FORM into a separate WEBPAGE.
I have something like the diagram below on my webpage. The user is
prompted to input his/her HTML Code in the FORM TEXTAREA. By pushing
the Make Webpage Button, a new window opens with the output of the HTML
contents they inputted. This way people can see what their HTML looks
like.
HTML FORM TEXTAREA (Where user inputs their HTML Data)
*******************************************
* <html> *
* <head> *
* <title> Webpage Title </title> *
* </head> *
* <body> *
* *
* User Inputs Web Contents *
* *
* </body> *
* </html> *
*******************************************
***********************
* Make Webpage Button *
***********************
Ive looked on the web and in google groups and havent found anything
that I can comprehend to any reasonable degree.
I get that I have to save the TEXTAREA contents as a .html file and
then open a browser window with that file name.
Im guessing its somethings I should be able to do with JAVASCRIPT or
possibly a CGI Script. Im not really up on either except for real basic
stuff.
If you have any ideas or directions to point me to, Id be grateful.
Also, is it better to save the file via a server as opposed to the
users hard drive? Whats the best/quickest way?
TIA
Teknowbabble