开发者

How to disable unsollicited ajax on standard components (h:commandButton) while using Icefaces?

开发者 https://www.devze.com 2023-02-19 01:20 出处:网络
Icefaces 2 has the annoying habit of enabling Ajax where I don\'t want it. 开发者_如何学JAVAIt works for a lot of things, but not all of them:

Icefaces 2 has the annoying habit of enabling Ajax where I don't want it. 开发者_如何学JAVAIt works for a lot of things, but not all of them:

  • for a commandButton which triggers a file download, the file isn't opened
  • if an exception occurs, it doesn't navigate to the exception page (specified in web.xml)

Putting a f:ajax tag around h:commandButton with disabled="true" solves it. I don't want to have to put it everywhere, however.

So, how to disable this by default?

Alternatively, I submitted a question for making the error page work even if the form is submitted by (unsollicited) ajax: how to make error page (http 500) work in IceFaces? .


As stated here: how to make error page (http 500) work in IceFaces?.

This can be disabled, as per http://wiki.icefaces.org/display/ICE/Configuration , by setting autorender context parameter to false in web.xml . But then, you need to explicitely enable this behavior on every icefaces form (you get an error otherwise).

0

精彩评论

暂无评论...
验证码 换一张
取 消