Let me know if this should be posted on StackOverflow instead - I'm not quite sure where it belongs
When calling a page via the JSTL <c:import>
tag or the JSP Include action, webMathematica gives results that are not consistent with the other components of the page. Consider the following example:
page1.jsp:
...
<c:url value="page2.jsp" var="x">
<c:param name="a" value="4" />
</c:url>
<c:import url="${x}"/>
...
page2.jsp
1. ${param.a}
2. <%= request.getParameter("a") %>
3. <msp:evaluate>MSPValueQ[$$a]</msp:evaluate>
4. <msp:evaluate>$ServletRequest@getParameter["a"]</msp:evaluate>
5. <%= request.getAttribute("javax.servlet.include.query_string") %>
6. <msp:evaluate>$ServletRequest@getAttribute["javax.servlet.include.query_string"]</msp:evaluate>
1 and 2 both return the correct value of 4. However, 3 and 4 both evaluate to the empty string. Furthermore, 5 gives the correct string "a=4", but 6 evaluates to the empty string.
My best guess is that webMathematica does not update it's parameters when the import is done, so $ServletRequest does not get updated with the new attribute and value of the new GET parameter is not set.
What is actually going on here?