I usually do it exactly as you described, with a hidden field that is called "Command" or "Action". There seems to be a split on whether this is a good practice or not. I, for one, like this way of doing it because you get to reuse code from the action class and you can very often do your CRUD logic without a proliferation of assorted actions for each noun. Some folks would suggest that you should create a new action class and refactor your design to move the logic that is shared either to a superclass or a helper class. I think this is also a valid way of doing it, but, can't see any overwhelming advantage over using a hidden field and sharing the same action class. If it eases your pain any, I am currently trying to poll users to see what their opinions on this matter are. We are currently building a framework/best practices application based on struts and this is a big point of divergence right now. We very much don't want to confuse novice users by saying you can do it this way OR that way without providing a good example of why/when to do it one way or the other.
-----Original Message----- From: Erez Efrati [mailto:[EMAIL PROTECTED] Sent: Tuesday, August 12, 2003 7:49 AM To: 'Struts Users Mailing List' Subject: Signup Wizard and Edit mode I have a user signup wizard running through several pages. After the signed up process is done I let the users update their registration information. I have an action named 'SignupAction'. Since I already wrote those pages I want to reuse them in the Edit actions. How can I do it? One way I thought of, since those pages already have their <html:form action="/SignupAction.do">, I will pass the SignupAction a hidden parameter with the mode or action = "Edit" and category="BasicInfo". That way it would that it is running in edit mode, and the category is the basic info (what was entered in the page #1 in wizard mode). 1) Can this work? 2) Is there a better way to do that? 3) How can I add arguments to the <html:form action="/SignupAction.do?<args>...">? can someone give an example here? Many thanks, Erez --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This message and its contents (to include attachments) are the property of Kmart Corporation (Kmart) and may contain confidential and proprietary information. You are hereby notified that any disclosure, copying, or distribution of this message, or the taking of any action based on information contained herein is strictly prohibited. Unauthorized use of information contained herein may subject you to civil and criminal prosecution and penalties. If you are not the intended recipient, you should delete this message immediately. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

