I want to have dialogs and where each dialog would have it's own iframe inside.
Why doesn't this work?
Why doesn't this work?
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<link rel="stylesheet" type="text/css" href="yuiext/resources/css/ext-all.css" />
<script type="text/javascript" src="yuiext/yui-utilities.js"></script>
<script type="text/javascript" src="yuiext/ext-yui-adapter.js"></script>
<script type="text/javascript" src="yuiext/ext-all.js"></script>
<script type="text/javascript">
Ext.onReady(function() {
dialog1 = new Ext.BasicDialog("win1", {
autoTabs:false,
width:500,
height:300,
shadow:false,
minWidth:300,
minHeight:250,
proxyDrag: true
});
dialog2 = new Ext.BasicDialog("win2", {
autoTabs:false,
width:500,
height:300,
shadow:false,
minWidth:300,
minHeight:250,
proxyDrag: true
});
dialog1.show ();
dialog2.show ();
});
</script>
</head>
<body>
<div id="win1">
<div class="x-dlg-hd">Google</div>
<div class="x-dlg-bd">
<iframe src="http://www.google.co.uk/" style="width: 100%; height: 100%; border: 1pxm solid black;" frameborder="0" />
</div>
</div>
<div id="win2">
<div class="x-dlg-hd">Freebasic forum</div>
<div class="x-dlg-bd">
<iframe src="http://www.freebasic.net/forum/" style="width: 100%; height: 100%; border: 1pxm solid black;" frameborder="0" />
</div>
</div>
</body>
</html>

|
#2
|
|
anyone?
![]() |
|
#3
|
|
Close your iframe tags. Worked for me.
![]() |
|
#4
|
|
Indeed. iframe tags are, unlogically, no singletons.
![]() |
|
#5
|
|
Tnx. didn't know that. works fine now
![]() ![]() |
|
#6
| |
|
Quote:
![]() |
本文讨论了一个关于HTML中iframe标签的使用错误,并给出了正确的解决方案。原本的问题在于将iframe当作单标签来使用,实际上它需要闭合标签。

1790

被折叠的 条评论
为什么被折叠?



