• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

scripting-invalid tag

 
Jeevitesh Singh
Greenhorn
Posts: 28
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
if we have scripting-invalid tag set true in the dd....
then does this mean that if i have a jsp with scripting code and i have disabled the scripting ..............
then will the fail to execute............
please help i have my scwcd exam tommorrow......
thanku...........
 
Sebastian Janisch
Ranch Hand
Posts: 1183
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You will get a horrifying exception when you call your JSP.
 
Jeevitesh Singh
Greenhorn
Posts: 28
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
then what way is the scripting-invalid tag helpful.....
i thought its there so that even though our jsp has scriptlets......
still we can just treat it as though its not there and work with the rest of the code in the jsp......
much like the same way assertions are are used in scjp 1.6........
 
Musab Al-Rawi
Ranch Hand
Posts: 231
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
the purpose is to disable scriptlets and REMIND developers not that they can't use them ... ignores scriptlets could be confusing, as you won't get what you expect.
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
then what way is the scripting-invalid tag helpful.....

Don't use scriptlets in JSP. This tag can act as a reminder to any evil trying to put some scriptlet in his JSP.
 
geeta vemula
Ranch Hand
Posts: 208
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In book it is mentioned that if we set el-ignored=true then el expressions are considered as template text. then does it consider the same way with scripting invalid too??
 
Sebastian Janisch
Ranch Hand
Posts: 1183
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
No, in that case the EL expression is printed as plain text.
 
Ankit Garg
Sheriff
Posts: 9577
33
Android Google Web Toolkit Hibernate IntelliJ IDE Java Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The names are explanatory themselves. scripting-invalid (beware, scripting is illegal, I'll throw an exception). el-ignored (do whatever you want, I'll just ignore whatever you are doing with EL) ...
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic