This week's book giveaway is in the Flex forum.
We're giving away four copies of Flex 4 in Action and have Tariq Ahmed, Dan Orlando, John C. Bland II & Joel Hooks on-line!
See this thread for details.
[Logo] JavaRanch » JavaRanch Saloon
  Search | FAQ | Recent Topics | Hot Topics
Register / Login


Win a copy of Flex 4 in Action this week in the Flex forum!
Reply Bookmark it! Watch this topic JavaRanch » Forums » Java » JSP
 
RSS feed
 
New topic
Author

JSP: make app crash if EL variable unknown or namespace not declared

manuel aldana
Ranch Hand

Joined: Dec 29, 2005
Messages: 307

Hi,

several times the page displayed fine though a corrupt data was used inside a JSP like:
...
${nonExistentVar.bla}
...


The same counts for using jsp tags where jsp-namespace are not declared:
<!-- c: namespace not declared in jsp header
<c:if.....>


Is there a way/configuration to make the app crash if such coding errors are inside JSP? It is really annoying if page shows up though JSPs contain wrong stuff. In my view this should be default setting....

thanks.

aldana software engineering blog & .more
Bear Bibeault
Author and opinionated walrus
Sheriff

Joined: Jan 10, 2002
Messages: 36550

The EL specification clearly states what conditions will result in errors and which will result in empty output. There are no settings to adjust this.

[Smart Questions] [JSP FAQ] [Books by Bear] [Bear's FrontMan] [About Bear]
manuel aldana
Ranch Hand

Joined: Dec 29, 2005
Messages: 307

I see,

for the EL side I think it is a very bad approach to filtering out buggy markup. I wished here EL would go the freemarker way, where at a empty you have to explicitly append a '?' to tell that it should produce empty string otherwise an exception is thrown.

aldana software engineering blog & .more
 
jQuery in Action
 
 
Reply Bookmark it! Watch this topic JavaRanch » Forums » Java » JSP
 
RSS feed
 
New topic
jQuery in Action