jquery - Should I implement "drafts" of content in my application? -
if design robust data-entry oriented web application asp.net mvc, consider implementing drafts content being edited? holds data while being edited , how manage user logins/logouts/session timeouts/navigating content being edited?
also if happen know jquery plugin handles , works fine asp.net mvc, feel free mention it.
should implement "drafts" of content in application?
only can answer question depending on customer's requirements.
what holds data while being edited , how manage user logins/logouts/session timeouts/navigating content being edited?
i recommend sending ajax requests @ regular intervals server side script associate draft logged in user , post being edited , save in datastore. while data being edited hold inside client browser (usually inside html <form>
element input fields).
when user submits data no longer considered draft , delete corresponding entry in drafts table , persist final revision. when user navigates page has draft functionality implemented check database whether draft exists content being edited , automatically prefill form values.
one of drawbacks of approach if user session expires no longer able save drafts @ regular intervals because won't able associate user. again use sessions sliding expirations , because of ajax requests sent @ regular intervals (smaller session timeout) session won't expire until user editing page.
another approach consists in storing draft on client. here consider using either persistent cookies or if browser supports html5 client storage.
Comments
Post a Comment