Hi All, I have an Application built on EJB-Struts framework. I need to implement internationalization on all jsp pages which we view. How can it be done ?
Necessity is the Mother of Invention. _______________________________________________________ Ramesh Mekkara Software Engineer HCL Technologies 109, Sapna Trade Center, P.H.Road Chennai - 84, India * [EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]> * Office #: +91-44-28221119 | Extn #: 2217 * Mobile #: +91-9840709983 ________________________________________________________ This message and any attachment(s) contained here are information that is confidential, proprietary to HCL Technologies and its customers. Contents may be privileged or otherwise protected by law. The information is solely intended for the individual or the entity it is addressed to. If you are not the intended recipient of this message, you are not authorized to read, forward, print, retain, copy or disseminate this message or any part of it. If you have received this e-mail in error, please notify the sender immediately by return e-mail and delete it from your computer. -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Friday, July 15, 2005 6:34 PM To: Struts Users Mailing List Subject: Re: Some advice Ok... mayby that an example This is a posible ActionForm..... the variable "flag" indicates the type of validation that needs public class CosaForm extends ActionForm { private String nombre = ""; private String apellidos = ""; private String telefono = ""; private String direccion = ""; private String flag = ""; //The hidden field public void reset(ActionMapping arg0, HttpServletRequest arg1) { nombre = ""; apellidos = ""; telefono = ""; direccion = ""; } public ActionErrors validate(ActionMapping arg0, HttpServletRequest arg1) { ActionErrors errors = new ActionErrors(); if(flag.equals("onlyName")){ if(nombre.trim().length() == 0) errors.add("validaForm", new ActionError ("error.name.void")); else if(flag.equals("onlyAddresTelephone")){ if(direccion.trim().length() == 0) errors.add("validaForm", new ActionError ("error.addres.void")); else if(telefono.trim().length() == 0 || telefono.trim ().length() > 9) errors.add("validaForm", new ActionError ("error.thelepone")); } return errors; } /** * */ public AnadirForm() { } public String getApellidos() {return apellidos;} public void setApellidos(String apellidos) {this.apellidos = apellidos;} public String getNombre() {return nombre;} public void setNombre(String nombre) {this.nombre = nombre;} public String getTelefono() {return telefono;} public void setTelefono(String telefono) {this.telefono = telefono;} public String getDireccion() {return direccion;} public void setDireccion(String direccion) {this.direccion = direccion;} } |---------+----------------------------> | | Rafael Taboada | | | <kaliman.forever@| | | gmail.com> | | | | | | 15/07/2005 14:20 | | | Please respond to| | | "Struts Users | | | Mailing List" | | | | | | | | | | | | | |---------+----------------------------> >--------------------------------------------------------------------------- -----------------------------------------------------| | | | To: Struts Users Mailing List <user@struts.apache.org> | | cc: | | bcc: | | Subject: Re: Some advice | >--------------------------------------------------------------------------- -----------------------------------------------------| Hi Basudeb Acharya for ur help... It's really that I want =) Ex.llitia2. I'd like you are more specific. My code in ActionForm is: ActionErrors errors = ventaForm.validate(mapping,request); if (errors==null || errors.isEmpty()) { //Do something because all is OK } else saveErrors(request,errors); -- Rafael Taboada Software Engineer Cell : +511-97753290 "No creo en el destino pues no me gusta tener la idea de controlar mi vida" --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]