jquery ui autocomplete suggestion are not closing after entering space between typed words

陌路散爱 提交于 2019-12-11 02:22:12

问题


Hi I have previously opened this thread How to tag users in feed like Facebook or Twitter does?. I am working with jquery autocomplete & so far I have this code with me.

Now when I am entering @user-name the suggestions are appearing. But when I hit spacebar the suggestions still remain there. Ideally suggestions should disappear as I hit space bar as we experience in facebook. Please help me to get the ideal behaviour. Thank you!


回答1:


Edit your code to add one more line to else scope on line number 45

else
{
    $( "#birds" ).blur().focus();
    return false;
}

I'm sure it will fix the problem.



来源:https://stackoverflow.com/questions/7886140/jquery-ui-autocomplete-suggestion-are-not-closing-after-entering-space-between-t

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