DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=25689>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=25689

Request attributes are unavailable to jspf included by pageContext.include()

           Summary: Request attributes are unavailable to jspf included by
                    pageContext.include()
           Product: Tomcat 4
           Version: 4.1.19
          Platform: Other
        OS/Version: Windows XP
            Status: NEW
          Severity: Normal
          Priority: Other
         Component: Jasper 2
        AssignedTo: [EMAIL PROTECTED]
        ReportedBy: [EMAIL PROTECTED]


I've a custom tag.  In its doStartTag, a request attribute is set before a jspf
is included, as follows:

this.pageContext.getRequest().setAttribute("foo", value);               
this.pageContext.include("/WEB-INF/jspf/part/text.jspf");

In the text.jspf, the request attribute should be printed out by:

<c:out value="${requestScope['foo']}"/>

However, no value is displayed.  

The same <c:out> line can display the request attribute if it is in the original
jsp that contains the custom tag.

If the text.jspf is renamed to text.jsp, the request value is printed out. 
Another workaround is to add the following into tomcat's web.xml:

<servlet-mapping>
  <servlet-name>jsp</servlet-name>
  <url-pattern>*.jspf</url-pattern>
</servlet-mapping>

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to