1) Script Title: Auto Save Form Value
2) Script URL (on DD): http://www.dynamicdrive.com/dynamici...tosaveform.htm
3) Describe problem: I have a complex Service Management program that I wrote, that is used internally in my business. It is mostly PHP, with a little bit of HTML on the forms. One of my users has a very bad browser habit, in that he likes to open all kinds of links using tabs. His bad habit is that he will close the browser, and lose the data he had entered in the service management program. He will open my program, start adding data to the Work Order he created for the piece of electronics he is working on, and go off in other directions, leaving the Work Order open and -not- saved. He closes the browser and BAM!, all his Work Order data is lost. I've told him that this is really a user issue but he argues that software should protect the (stupid) user. Hence, I went off on a search to do like MS Word does, which asks if you want to save, on exit. Unfortunately, this is *not* a feature built-in to browsers !!
So, when I found your script, it was just GREAT. Easy to implement, and fairly straight forward to understand. Works exactly as 'advertised'. NICE !!
So the problem: I have up to 5 buttons on a form, one that saves via Submit button, and others that are -not- type="submit" but type="button". I can change type="button" to "submit", and when the user clicks that, it cancels your Auto Save Form script like it is supposed to. The issue I have is that the form runs the usual Submit code, and *NOT* the code associated with that buttons OnClick event. Basically, the Submit event fires before the OnClick event, running the wrong code. Apparently, this is normal browser behavior.
So the issue/enhancement would be to have a programmatic method to cancel the autosave functionality -or- possibly a custom ID or CLASS tag associated with a button, that would also cancel the autosave.
Any ideas ??