[Logo]
Forums Register Login
servlet linking and requestdispatcher
I am working on a project, most stuffs are form validation, send email, and update database. Because I do not want to write a servlet for every single form, I am thinking about write several small servlets, changable information store in property files and link them together using the property file.
However, my coworker says this is not a good idea. Well anyone has any suggestions?
Finally, after I use RequestDispatcher.forward, the page's javascript got messed up. Is it because of tomcat? Anyone had similiar experience?
Thanks
Of course whenever possible it is better to have one servlet to do all you stuff. Besides, form checking and database updates are pretty forward routines. Have you considered using JavaBeans and JSP?
Well, I need very strict seperation between presentation and logic, all content will go through another process for update. That is why I choose servlet. If could, I would rather use jsp which I am more familiar with.
All databse access will use bean, I wrote two small servlet to handle form validation and email. If the client decide to add more similiar stuff, I would just change the property file.
Well, maybe client would not make that much changes, maybe I should wrote singel servlet to handle one process.
Thanks
Wink, wink, nudge, nudge, say no more ... https://richsoil.com/cards



All times above are in ranch (not your local) time.
The current ranch time is
Dec 14, 2017 06:29:03.