iframe允许用户输入?!? [英] Iframe allows users to type?!?
问题描述
大家好,
我目前正在使用iframe在我的网站上显示HTML提要.但是,该文本可由用户编辑,他们无法保存任何内容,但效果仍然不佳.
通过在iframe上使用覆盖层,我能够为IE以外的所有浏览器停止此功能,并且无法解决如何在IE中停止该功能.
目前这是代码
Hi guys,
I am currently using an iframe to display a HTML feed on my website. However the text is editable by users, they cannot save anything but its still not good.
By using an overlay over the iframe I was able to stop this feature for all browsers apart from IE and cannot work out how to stop this in IE.
Currently this is the code
<div id="IframeWrapper" style="removed: relative;">
<div id="iframeBlocker" style="removed: absolute; removed 0; removed 0; width: 100%; height: 100%"></div>
<iframe id="NewsWindow" src="http://bannonhoa.webs.com/index.htm" designmode="off" width="215" height="223" marginwidth="0" marginheight="50" frameborder="0" scrolling="auto" style="border: #000000 1px solid;" ></iframe>
我真的是出于想法,所以任何人都能提供的帮助将不胜感激.
Im truly out of ideas so any help anyone could provide would be greatly appreciated.
推荐答案
我使用以下内容
I use the following
<div id="divDisableGrid" style="height: 100%; width: 100%; position: absolute; background-color: #f4f8fa; filter: alpha(opacity=50); -moz-opacity: 0.5; opacity: 0.5">
</div>
只需更改背景颜色或不透明度即可根据需要工作.将此div放在标签内.
Just change the background-color or the opacity to work how you need it. Put this div right inside of your tag.
这篇关于iframe允许用户输入?!?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!