How to activate spellchecking for a contentEditable div in a UIWebView?

六月ゝ 毕业季﹏ 提交于 2019-12-21 03:25:11

问题


UIWebView (iOS 5.0) does not show the red-squiggly spelling correction underlines for this:

id html= @"<div spellcheck=\"true\" contenteditable=\"true\"></div>"
[webView loadHTMLString:html baseURL:nil];

Is it possible to get them?


回答1:


There are some HTML tag properties available by Apple Safari Guidelines

autocomplete: If off, deactivates automatic completion for an input element; If on, activates automatic completion for the element. Related Tags “input” Availability Available in Safari 1.0 and later. Available in iOS 1.1.1 and later.

autocorrect: If off, deactivates automatic correction for a form or input element; If on, activates automatic correction for the element. Availability Available in iOS 1.1.1 and later.

Hope this might be useful to you.



来源:https://stackoverflow.com/questions/7927605/how-to-activate-spellchecking-for-a-contenteditable-div-in-a-uiwebview

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!