【求助】delphi7 使用Delphi-EmbeddedWB在模态窗口提交表单时调用了IE

pdw2009 2017-11-22 05:25:17
现在要做个浏览器,开发环境dephi7,浏览器控件使用Delphi-EmbeddedWB ,html页面使用模态打开了一个窗口,打开的模代窗口的html 代码如下:



<!DOCTYPE html>
<html lang="zh">
<head>
<meta charset="UTF-8"></meta>
<title>Title</title>
<link rel="stylesheet" href="http://cdn.static.runoob.com/libs/bootstrap/3.3.7/css/bootstrap.min.css"></link>
<script src="http://cdn.static.runoob.com/libs/jquery/2.1.1/jquery.min.js"></script>
<script src="http://cdn.static.runoob.com/libs/bootstrap/3.3.7/js/bootstrap.min.js"></script>
<script>
/*
var args = {
"appid":"4481",
"uid":"peidw",
"signature":"1dG4eASyEHsiEn2AJZsyFwudwVlhPTQ0ODEmbT1hcGlfYXV0aCZ0PTExNTA5MDk1NjQ5ODY1JmU9NjAw",
"redirect":"http://fkwx.ittun.com/authResult"
};
for (var arg in args) {
alert(arg+" "+args[arg]);
}
*/
function openmodel(){
var obj = new Object();
obj.name="51js";
window.showModalDialog("model.html",obj,"dialogWidth=600px;dialogHeight=300px");
//window.external.showModalDialog("model.html",obj,"dialogWidth=600px;dialogHeight=300px");
}

</script>
</head>
<body>
非嵌套页里打开ireame
  <a href="#" onclick="openmodel()">打开模态一个窗口</a>

<p><hr></hr></p>
<iframe src="iframe.html" scrolling="yes" height="600px" width="100%">

</iframe>


</body>
</html>



model.html 文 件内容:

<!DOCTYPE html>
<html lang="zh">
<head>
<meta charset="UTF-8"></meta>
<title>Title</title>
<link rel="stylesheet" href="http://cdn.static.runoob.com/libs/bootstrap/3.3.7/css/bootstrap.min.css"></link>
<script src="http://cdn.static.runoob.com/libs/jquery/2.1.1/jquery.min.js"></script>
<script src="http://cdn.static.runoob.com/libs/bootstrap/3.3.7/js/bootstrap.min.js"></script>
<script>
var obj = window.dialogArguments
//alert("您传递的参数为:" + obj.name)
function closex() {
document.getElementById("frm_1").submit();
}
</script>
</head>
<body onunload="closex()">


<form class="form-horizontal" role="form" id="frm_1" target="frm_x" action="/formSub">
<div class="form-group">
<label for="firstname" class="col-sm-2 control-label">名字</label>
<div class="col-sm-4">
<input type="text" class="form-control input-sm" id="firstname"
placeholder="请输入名字">
</div>
</div>
<div class="form-group">
<label for="lastname" class="col-sm-2 control-label">姓</label>
<div class="col-sm-4">
<input type="text" class="form-control input-sm" id="lastname"
placeholder="请输入姓">
</div>
</div>
<div class="form-group">
<div class="col-sm-offset-2 col-sm-4">
<div class="checkbox">
<label>
<input type="checkbox"> 请记住我
</label>
</div>
</div>
</div>
<div class="form-group">
<div class="col-sm-offset-2 col-sm-4">
<button type="button" onclick="javascript:window.close()" id="btn_submit" class="btn btn-default">登录</button>
</div>
</div>
</form>

</body>
</html>


在模态窗口里 model.html 点击“登陆”,做表单提交时,调用了IE来做这表单提交,请求这怎么解决呢。
我操作的流程 如下:










公网访问我的测试页面地址:http://fkwx.ittun.com/test 晚上是开着的,随时可以试
求解求办法和思路!!!谢谢




...全文
511 2 打赏 收藏 转发到动态 举报
写回复
用AI写文章
2 条回复
切换为时间正序
请发表友善的回复…
发表回复
pdw2009 2017-12-01
  • 打赏
  • 举报
回复
lyhoo163 2017-11-22
  • 打赏
  • 举报
回复
EmbeddedWB调用的就是IE内核。

5,388

社区成员

发帖
与我相关
我的任务
社区描述
Delphi 开发及应用
社区管理员
  • VCL组件开发及应用社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧