Devone

Can I Create an HTML File Using JavaScript?

Asked by Devone 2 years ago html javascript file


Andrew Miller
0
 
Almost,..... You can use open a new window and write text to it, that text would be HTML tags and content.

Window_DOT_open('','_blank');
    document_DOT_write("<HTML> Create HTML Using JavaScript")
     document_DOT_write("")
to create an HTML document that can be opened in a new window on the fly but by design and for security reasons, regular JavaScript scripts in web pages are not
allowed to write to the local file system.



Or build a variable that is a concatenation of various HTML tags and
content then write that variable to the new window

by Andrew Miller 2 years ago

Answer this question

Can I Create an HTML File Using JavaScript?

0 errors found:

 
0