【问题标题】:jquery .is(":focus") returning false on ios webviewjquery .is(":focus") 在 ios webview 上返回 false
【发布时间】:2019-06-02 13:59:40
【问题描述】:

我花了几个小时试图找出为什么在一个名为 onInput 的函数中的 $('#something').is(":focus") 在我输入时在 ios webview 的输入字段上返回 false。

如果你知道为什么我也会很高兴知道它。

【问题讨论】:

    标签: javascript jquery ios webview focus


    【解决方案1】:

    我找不到原因,但能够通过使用纯 javascript 检查 document.activeElement.id == 'something' 是否绕道而行。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2020-04-19
      • 2016-11-14
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2022-01-02
      相关资源
      最近更新 更多