i have a struts 2 form in which all the fields are mapped with the bean and are working perfect . the moment i added this html tag <input type="text" name="customername" id="customername" > and i tried to submit the form ..it is not going to the desired add method ..but it goes to the listing page where it should suppose to come after adding.......but the most strange thing is when i remove the name attribute of the above input tag i.e <input type="text" id="customername" > ..its working fine but now of no use because i coudnt get any thing from request.getParameter("customername") in add method...i have tried many names in place of customername ..but no success. ............any idea whats going on ...........
i have tried changed the names also ...but what i have caught after hours... is that when i delete four text boxes and remain only with one ...it works ... another thing if i delete the name attribute of all the tags ..it works also fine.................sick n tired of this problems ..any idea or bug posted before like caching problem with ie or ???
Joined: Feb 15, 2005
Originally posted by mudassir shahab: yes i have tried this also ..no luck
"no luck" doesn't tell me anything.
Here's what I'd recommend: Try again implementing this with Struts <s:textfield> tags. If you get an error message or other problem, describe it in detail. Also show us your full JSP, Action class, and the entries in your struts.xml file as well as any other xml config files you might be using. Given this information, we might be able to help you figure out what's going wrong. [ July 25, 2007: Message edited by: Merrill Higginson ]