I have a search screen where in if there is an exact match I have to show the detail page diretcly. If the search returns more than one record then I show a list of records. The user double clicks and then reaches the detailed page.
When there is a direct match inside my action class.
if search returns a list of records
Firstcase the url is http:.../'showGroupDetails.do secondcase my url is like http:.../'showGroupDetails.do?groupid=1
I want same kind of url for both. how can this be achieved? Is there way I can change my struts-config to accept query parameter?
This should be very easy...just append the parameters to the end of the path after calling findForward. The problem is that a forward cannot be modified after it is created. Maybe there is an easier way to do this, but I created this utility method for doing this: