Hello,
I'm trying to create an "auto-save" function in my web-app. We have several tabs the user may navigate through. Rather than having to hit the save button each time, I want to call the save action for the page b/f loading the next page.
There are too many tabs to "hard code" so I'm looking for a generic solution.
What I need:
A javascript method that captures all of the request parameters (onunload) - then put them in a hashmap (or something). I plan on overriding the request processor class in
struts.
psuedo code: (sorry - i'm a novice at javascript)
{
HashMap hm =new HashMap();//to store parms and values
allRequestParameters = ?// somehow get all request parameters? is there a method for this?
for(int i = 0; i<allRequestParameters.size();i++){
hm.put(allRequestParameters.getParameter(i), allRequestParameters.getValue(i));
}
}
Can you help?
[ April 26, 2005: Message edited by: chris gar ]