1

我正在为工作做点什么。这是一项高度重复性的任务,填写一份关于可以在短期内(如 5 分钟)回顾的任务的小调查会很有用

我喜欢jquery.survey 模块。 调查看起来很棒。现在我可以使用提示或一些帮助来获取该调查的输出,以保存 3-4 个会话以显示在侧边栏中。

我有技术限制,只能使用 javascript。我无法写入 txt 日志并从中读取(即 6 个问题),并且我无法使用 PHP 或服务器软件,因为我无权访问它。我仅限于桌面上的一个 html 文件。

4

1 回答 1

1

You could just add to the DOM by overriding the "Submit" form button and pushing the resulting form data into a <div> or <p> that you display on the same page.

This is, however, highly fragile as any reload will wipe out the data (since you can't save to disk via javascript limitations)... what you're saving to is the browser in-memory state of your page.

If you actually want to save the work you had entered, you need local filesystem access or server access, there's just no way around it due to the sandboxing of browser javascript.

于 2009-09-03T20:19:20.470 回答