且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

具有多个运算符的JSTL条件

更新时间:2022-06-10 04:51:29

这看起来很有效(尽管有点笨拙;几种样式混合在一起,不需要进行布尔比较).

This looks valid (albeit a bit clumsy; several styles are mixed and that boolean comparison is unnecessary).

浏览器检索无效的HTML时可以空白.我敢打赌,在代码中还有一些Java代码在响应已经提交时引发了异常.由于响应已经提交,因此服务器将无法完整显示错误页面(尽管它将记录异常).浏览器最终将收到带有不完整HTML的半生半熟的响应,该HTML无法被浏览器以任何明智的方式解释,因此它将变为空白.

A browser can go blank when it retrieved invalid HTML. I'd bet that there's some Java code further down in the code which threw an exception while the response is already committed. As the response is already committed, the server won't be able to show the error page in its full glory (although it would log the exception). The browser will end up with a halfbaked response with incomplete HTML which the browser can't interpret in any sensible way, hence it will go blank.