tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Donnchadh Ó Donnabháin <d_odonnabh...@vistech.ie>
Subject Re: nested jsp:includes in tomcat3.2beta3
Date Sun, 10 Sep 2000 14:44:24 GMT
Larry Isaacs wrote:
> I'm not sure how your contexts are set up, but going two parents deep from /gaa-hurling/index.jsp
appears to be leaving the web application.  jsp:include uses a relative URL which isn't allowed
to leave the web application for security reasons.


 Thanks for the response and sorry for not replying sooner. I should
 have said /gaa-hurling/columnists/index.jsp instead of 
/gaa-hurling/index.jsp. Everything is within the same context. 
 The structure of the relevant parts of the context is as follows:

/gaa-hurling
        /columnists
                   /index.jsp

/common
        /rightnavs
                   /hurlinghome.jsp

/tips
        /tip.jsp


/gaa-hurling/columnists/index.jsp contains the following include:

<jsp:include page="../../common/rightnavs/hurlinghome.jsp" flush="true"
/>

/common/rightnavs/hurlinghome.jsp contains the following include:

<jsp:include page="../../tips/tip.jsp" flush="true" />



> Are there parts of the URL not shown below?  A simple test I tried that stayed within
the web application worked.  If your jsp:includes aren't trying to leave the web application,
please provide more detail and I'll check further.
> 


My main point is that if an absolute path is used, the following
filename
 is used for the generated servlet source
 
_0002ftips_0002ftip_0002ejsptip_jsp_0.java

whereas tomcat3.2beta3 generates a different one for each page within
 which it is included if a relative path is used e.g.

_0002fgaa_0002dhurling_0002fcolumnists_0002f_0002e_0002e_0002f_0002e_0002e_0002fcommon_0002frightnavs_0002f_0002e_000
2e_0002f_0002e_0002e_0002ftips_0002ftip_0002ejsptip_jsp_0.java

resulting in file paths which are too long.



   Donnchadh


-- 

// Donnchadh Ó Donnabháin  mailto:d_odonnabhain@vistech.ie
// Vistech Software Ltd.   http://www.vistechsoftware.com
// Building 7, Cork Airport Business Park, Cork, Ireland
// Ph. +353-21-4315007      Fax +353-21-4315066


Mime
View raw message