Put your text ad here
WestNIC provides reliable web hosting services
This FAQ answers one of over 700 Web development questions submitted by Code Style readers. Sign-up to our premium content service to view the full answer.
A: It is not possible to create files on the client's computer using Javascript. This type of action is excluded from the Javascript language because it would be a serious security hazard. The only form of local file storage available through Javascript is cookies, whose behaviour and contents are strictly prescribed.
Of course it is possible to use Javascript to generate file content in a Web browser window and invite people to save the contents. Internet Explorer and Firefox users can use the File menu Save as... option directly, but Opera and other browser users may have to copy the text into another application to save it.
… premium content omitted
Access all premium content for $50: sign-up below.
How can I create a file on the client side?
Come inside, access hundreds of premium content answers. One payment grants life membership to hundreds of developer FAQs.
The PayPal service allows you to pay securely and independently in your own currency. Payments are billed to Metacentric Internet Limited. We never handle your credit card details.
Direct access to hundreds of answers to common Web development questions with full working examples and links to other Web resources. Your subscription provides full answers to all premium content questions including those listed below, plus:
onclick event on my button is not working! (stub article)
iframe browser and filter the URLs? (stub article)