Click here to Skip to main content
12,898,392 members (57,448 online)
Rate this:
Please Sign up or sign in to vote.
See more: Javascript jQuery HTML5
i am developing mobile web app for conducting survey in html5. i need to save user responses in file preferably in csv format. How can do it? i am stuck with storing part.......... please please help me.

I cannot use activex for dat purpose coz app needs to work on android+ windows tablet.

thanx in advance.
Posted 26-Jul-12 18:16pm
Updated 13-Apr-17 16:52pm
Rate this: bad
Please Sign up or sign in to vote.

Solution 1

Does this[^] help?
Rate this: bad
Please Sign up or sign in to vote.

Solution 2


<script language="Javascript">
function download(filename, text) {
  var pom = document.createElement('a');
  pom.setAttribute('href', 'data:text/plain;charset=utf-8,' + 
  pom.setAttribute('download', filename); = 'none';
function addTextHTML()
{ = + ".html"
function addTextTXT()
{ = + ".txt"


<form name="addtext" onsubmit="download(this['name'].value, this['text'].value)">
<textarea rows="10" cols="70" name="text" placeholder="Type your text here:"></textarea>
<input type="text" name="name" value="" placeholder="File Name">
<input type="submit" onclick="addTextHTML();" value="Save As HTML">
<input type="submit" onclick="addTexttxt();" value="Save As TXT">
Kats2512 14-Apr-17 1:41am
Do you really think the person who asked the question would still be looking for an answer after 5 long years?

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

    Print Answers RSS
Top Experts
Last 24hrsThis month

Advertise | Privacy | Mobile
Web01 | 2.8.170424.1 | Last Updated 13 Apr 2017
Copyright © CodeProject, 1999-2017
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100