2

Hey guys I need to implement "Save as Draft" Feature. The logic for this that I have thought about goes this way.

Logic: On click of "Save as Draft" button I would add an event to store the contents of my web applicationin a temp db and return the control to Home Page.

Problem: Implementation using js and mootools if incase there are some features available in this framework .

3
  • Are you using localStorage, or some other kind of client-side storage? Otherwise, this involves far more work on the server than on the client. Commented Oct 5, 2011 at 20:25
  • I am making use of global storage variable called sessvars if you are aware on client side itself.This would actually be a list or array containing the 'Post' to be send in my action call to server. Commented Oct 5, 2011 at 20:35
  • If the "contents of your web application" can be JSON encoded, then put it in local storage. If you are worried about backwards compatibility, there are libraries like github.com/jeremydurham/persist-js Commented Oct 9, 2011 at 19:00

1 Answer 1

3

If you're looking for something similar to how StackOverflow and other Stack Exchange sites "save" your question, even if you exit the browser and come back... then what Ryan suggested (localStorage) is what you'd be looking to implement.

More info

Hell, even if not, try using it anyway. The only downside is that localStorage is HTML5, and thus support in older browsers is spotty at best. (For all intents and purposes, IE8+ and FF3.5+ support localStorage)

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.