如何使用 Javascript 自动完成阿拉伯语?
我的页面上有一个文本框,具有自动完成/建议功能。问题是它是阿拉伯语的,一旦单词的格式发生变化,它就不会建议正确的匹配短语。例如,如果我在文本框中输入“ä”,它会建议所有带有“ä”的单一形式单词,但不会建议其中一种连接形式中存在“ä”的单词/短语(例如它不会建议“???”)。
I have a text box on a page with auto complete/suggest functionality. The problem is that it is on Arabic and once the format of the word changes, it does not suggest correct matching phrases. For example if I type "ل" in the text box, it will suggest all the words with "ل" in its single form but it will not suggest words/phrases where "ل" is present in one of the joining forms (for example it will not suggest "لاهور").
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
标准自动完成使用子字符串,这对于在某些上下文中使用时字符可能会发生变化的语言(例如阿拉伯语)没有用。
我不知道有哪个网络框架可以处理这种情况。
您将需要编写自己的自动完成代码。
The standard autocomplete uses substring which isn't useful for languages where a character can change when used in some context (like in Arabic).
I'm not aware of a web framework that handles this case.
You will need to write your own autocomplete code.