【问题标题】:Make specific elements in designMode iframe read-only?将designMode iframe中的特定元素设为只读?
【发布时间】:2010-07-04 22:33:45
【问题描述】:

我有一个将 designMode 设置为“on”的 iframe。在其中,我有一个用户应该能够输入的 div,并且在 iframe 中,我还有另一个用户不应该能够输入的 div。

有没有办法做到这一点?在我的情况下,使用 contentEditable 不是解决方案。

【问题讨论】:

    标签: iframe designmode


    【解决方案1】:

    -moz-user-select: none;-moz-user-modify: read-only 应用于元素。还有-webkit 等价物。请记住,designMode 在 Internet Explorer 中不起作用。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2022-12-19
      • 2014-07-12
      • 1970-01-01
      • 2012-08-22
      相关资源
      最近更新 更多