我有一个简单的隐藏表单,其目的是通过单击按钮将响应重定向到一个新窗口。它在Internet 9和chrome中工作得很好,但在Firefox11中,当弹出块打开时,它会给我一条警告信息。
错误消息
表格无法提交。造成这种情况的最可能原因是上载字段中的无效值。
虽然我没有试图上传任何文件的地方。
DynamicForm代码
dojo.provide("amk.geo.DomainCore.forms.SearchForm");
amk.geo.DomainCore.forms.SearchForm = function() {
/**
* Resource bundle.
* @type Object
*/
this.bundle = amk.geo.tools.bundles.Application;
this.formID = null;
this.controller = null;
this.resBundle = amk.geo.app.framework.controller.AppController.getResourceBundle("amk.geo.DomainCore.Resources");
this.initWidget = function() {
this.Super("initWidget", arguments);
this.formID = "SearchForm";
var params = [
{type: "hidden", name: "EMAIL_ID" },
{type: "hidden", name: "PORTAL_PSSWD"},
{type: "hidden", name: "PROJECT_ID"},
{type: "hidden", name: "fsquery"},
{type: "hidden", name: "PRODUCT_VER"},
{type: "hidden", name: "PRODUCT_NAME"},
{type: "hidden", name: "ORIGIN"}
];
this.setItems(params);
this.action = "https://xxxx.com/default.asp";
this.method = "POST";
this.target = "_blank";
this.canSubmit = true;
};
this.onLoad = function(){
this.submit();
}
}
// define class
isc.ClassFactory.definePackageClass(
"amk.geo.DomainCore.forms.SearchForm", // class name
isc.DynamicForm // superclass
);我怎样才能摆脱这条警告信息?(如果我向弹出窗口阻止程序添加了异常,它将在没有任何警告消息的情况下重定向)

请帮帮忙。谢谢你
发布于 2013-05-15 10:57:57
我通过在onLoad函数之后添加下面的行来解决我的问题
// Override DynamicForm formSubmitFailed function to disable warning alert in Firefox v11 when popups are blocked
this.formSubmitFailed = function(){}您甚至可以查看SmartClient文档以获得更多信息。
https://stackoverflow.com/questions/16558115
复制相似问题