Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/html/88.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Html 表中的Iframe_Html_Iframe_Html Table - Fatal编程技术网

Html 表中的Iframe

Html 表中的Iframe,html,iframe,html-table,Html,Iframe,Html Table,我试图在表的tbody部分添加iframe。这是到目前为止我的代码 <tbody> <tr> <td><div> <iframe class="tabContent" name="tabIframe2" frameborder="0"></iframe> <p>Text</p> </iframe>

我试图在表的tbody部分添加iframe。这是到目前为止我的代码

<tbody>
    <tr>
        <td><div>
        <iframe class="tabContent" name="tabIframe2" frameborder="0"></iframe>
            <p>Text</p>
        </iframe>
        </div></td>
    </tr>
</tbody>

正文


但是,文本不会出现在iframe中。它在iframe下面,在我的表格中。如何修复此问题?

需要标记
iframe
才能将另一个HTML页面插入到您的页面中。

使用的示例:

<iframe src="http://stackoverflow.com"></iframe>

不能在
iframe
标记中写入任何HTML。

用于将文件嵌入到另一个文件中。在irame所在的文件中,必须给出要插入的页面的源

像这样使用- 您的文件

<tr>
        <td><div>
        <iframe class="tabContent" name="tabIframe2" frameborder="0" src="test.html">
        </iframe>
        </div></td>
    </tr>

文件以嵌入“test.html”

<p>Text</p>
文本


您可以使用javascript.Wow在iframe中编写内容。有趣。谢谢,我不知道:)我能问你一个问题吗?为什么不使用
ifrm=ifrm.contentWindow | | ifrm.contentDocument.document | ifrm.contentDocument?实际上,我喜欢用这种方式做得更好,因为如果我进行调试,我可以更快地控制代码。