A Thing or Two About Struts Framework
Based on my experience while doing my final project, there's a thing or two that we must remember while working using Struts framework.
First of all, please follow the Java coding standards. I've once have an error just because I use first capital letter on an attribute of a class. Eclipse did generate the getter and setter, but somehow the Struts can't recognize them. By changing it to lower case, problem solved. -Case closed-
Secondly, regarding checkbox(es), Struts ONLY sent data when the checkbox is checked. If you have a form with checkbox which checked by default and user unchecked it, somehow Struts doesn't detect the changes. To resolve it, you have to check the parameter using request.getParameter("
Actually, I still have some problems while using Struts framework. When I try to use struts-config.xml to configure database connection, it yields error code. In my final project, I put the database configuration in MessageResources.properties. I know this one is not good, but hey.. It works :p -guess it's not over yet-
1 Comments:
"In my final project, I put the database configuration in MessageResources.properties. I know this one is not good, but hey.. It works :p -guess it's not over yet-"
how the hell did you do that?
Post a Comment
<< Home