File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes JSP and the fly likes question on re-using jsp pages. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » JSP
Bookmark "question on re-using jsp pages." Watch "question on re-using jsp pages." New topic

question on re-using jsp pages.

chandru ram

Joined: Jul 03, 2002
Posts: 18
Hi All,
Consider an application that has many different flows like addition,modification of a record etc.Each flow has to show a jsp page in different ways. for ex consider the following:

there is a page jsp1.jsp.If the flow is addition of a record, the jsp1 should show some values as text boxes and drop-downs.But if the flow is modification then the jsp1 should show the same fields as lables instead of textboxes.

If the number of such conditions are more then it results in lot of if-else conditions in the jsp page.If we write two separate jsp pages one for addition flow and one for modification flow (e.g jsp1_add.jsp and jsp1_mod.jsp) then if there is a change like adding a new field etc, then it has to be done at two places.

So what is the best solution for this.Does using Tiles solve this.

Thanks in advance,
Chandru ram
I agree. Here's the link:
subject: question on re-using jsp pages.
It's not a secret anymore!