tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Allistair Crossley" <Allistair.Cross...@QAS.com>
Subject RE: web.xml
Date Thu, 17 Mar 2005 12:26:29 GMT
yes, another (more generic) solution would be a similar servlet mapping but route all requests
to a servlet capable of then forwarding to the request URI + .jsp

 <servlet>
    <servlet-name>convertToJspServlet</servlet-name>
    <servlet-class>my.com.ConvertToJspServlet</servlet-class>
  </servlet>
  
  <servlet-mapping>
    <servlet-name>convertToJspServlet</servlet-name>
    <url-pattern>/*</url-pattern>
  </servlet-mapping>

In the ConvertToJspServlet servlet you would obtain the request.getRequestURI or mapping and
use a RequestDispatcher to add a .jsp suffix.

At least then you don't have to add mappings in web.xml for all your JSPs.

Just thinking out loud ;) ...

> -----Original Message-----
> From: Markus Schönhaber [mailto:mailing-tomcat-user@schoenhaber.de]
> Sent: 17 March 2005 12:22
> To: Tomcat Users List
> Subject: Re: web.xml
> 
> 
> Am Donnerstag, 17. März 2005 13:17 schrieb Omar Adobati:
> > I think that he need something working not just only with welcome
> > pages, or, maybe I have miss understood.
> >
> On re-reading the OP it seems to me that I misunderstood (and 
> Allistair 
> propably too), not you.
> 
> Regards
> mks
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
> 
> 


<FONT SIZE=1 FACE="VERDANA,ARIAL" COLOR=BLUE> 
-------------------------------------------------------
QAS Ltd.
Developers of QuickAddress Software
<a href="http://www.qas.com">www.qas.com</a>
Registered in England: No 2582055
Registered in Australia: No 082 851 474
-------------------------------------------------------
</FONT>


---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Mime
View raw message