Forums Register Login

scripting-invalid tag

+Pie Number of slices to send: Send
Hi,

I have put in the DD the following:

<web-app xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd" version="2.4">

<jsp-config>
<jsp-property-group>
<url-pattern>*.jsp</url-pattern>
<scripting-invalid>true</scripting-invalid>
</jsp-property-group>
</jsp-config>

</web-app>

I tried this jsp below named example.jsp located under context root,

<html>
<body>
10 x 5 = ${10 * 5} <br>
2 * 3 = <%= 2 * 3 %> <br>
</body>
</html>

The weird part is that it gives an output of

10 x 5 = 50
2 * 3 = 6

It seems that the jsp expression has been evaluated...
This should not work right? As I have stated in the DD that scripting is invalid... Am I missing something here?
+Pie Number of slices to send: Send
Hi,

Sorry... false alarm! I haven't refreshed the file... This was my bad!

I was able to get this message now....

org.apache.jasper.JasperException: /example.jsp(4,11) Scripting elements ( <%!, <jsp eclaration, <%=, <jsp:expression, <%, <jsp:scriptlet ) are disallowed here.
The problems of the world fade way as you eat a piece of pie. This tiny ad has never known problems:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com


reply
reply
This thread has been viewed 3008 times.
Similar Threads
<scriptlet-invalid> tag
el-ignored query
scripting-invalid tag
scripting-invalid question
scripting-invalid wierd behavior
More...

All times above are in ranch (not your local) time.
The current ranch time is
Mar 28, 2024 02:01:11.