Datalist(用于自动提示)在某些系统上没有显示crome。 [英] Datalist (for autosuggestion) not showing in crome on some systems.
问题描述
你好每个人,
我只在一些系统上遇到问题而不是全部。我有一个输入类型=带有列表属性的文本。这里是代码:
hello Everyone,
I am facing a problem only on some systems not no all. i have a input type=text with list attribute. here is code:
<input type="text" name="txtUserId" id="txtUserId" list="UID" autocomplete="off" class="form-control">
<datalist id="UID"></datalist>
这个数据列表中的
我加载数据,当我开始在文本框中输入时,这个数据列表渲染。它工作正常
但在某些系统中,它没有显示。我检查页面并看到数据已加载但未显示。在该系统上,chrome的版本是50.0.2661.75。我google了很多但没找到任何解决方案。我怎么解决这个问题。
谢谢
我尝试过的事情:
in this datalist i load data and when i start type in textbox then this datalist render. it works fine
but on some system in chrome it not showing. i inspect the page and saw data is loaded but not shown. on that system the version of chrome is 50.0.2661.75. I googled a lot but not found any solution. how i resolve this.
Thanks
What I have tried:
<input type="text" name="txtUserId" id="txtUserId" list="UID" autocomplete="off" class="form-control">
<datalist id="UID"></datalist>
I found solution. i have removed datalist and add autocomplete function of jquery on textbox. which works fine on all systems for me.
<input type="text" name="txtUserId" id="txtUserId" list="UID" autocomplete="off" class="form-control">
Here is Jquey function:
(#txtUserId)。autocomplete({
source:function(request,response) ){
var p_length =
("#txtUserId").autocomplete({ source: function (request, response) { var p_length =
(#txtPincode)。val();
if(p_length.length < 14 ) {
("#txtPincode").val(); if (p_length.length < 14) {
这篇关于Datalist(用于自动提示)在某些系统上没有显示crome。的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!