2017-04-19 105 views
0

我有aspx頁面上的兩個自動完成擴展。autocompleteextender在IE缺少一個列表項

<div class="wrapper left"> 
     <div class="col214 left label"> 
      Location Name 
     </div> 
     <div class="col234 left"> 
      <asp:TextBox ID="txtLocationName" CssClass="col225 tb" runat="server"></asp:TextBox> 
      <loc:AutoCompleteExtender ServiceMethod = "getLocationDetails" MinimumPrefixLength="4" CompletionInterval="10" EnableCaching="true" CompletionSetCount="10" 
      TargetControlID="txtLocationName" ID="AutoCompleteLocation" runat="server" FirstRowSelected="false" DelimiterCharacters="," ShowOnlyCurrentWordInCompletionListItem="true" ></loc:AutoCompleteExtender>    
     </div> 
    </div> 
    <br /> 
    <div class="wrapper left"> 
     <div class="col214 left label"> 
      Clinician Surname 
     </div> 
     <div class="col234 left"> 
     <asp:TextBox ID="txtClinicianSurname" CssClass="col225 tb" runat="server"></asp:TextBox> 
     <sur:AutoCompleteExtender ServiceMethod="getClinicianDetails" MinimumPrefixLength="2" CompletionInterval="100" EnableCaching="true" CompletionSetCount="10" 
     TargetControlID="txtClinicianSurname" ID="AutoCompletSurname" runat="server" FirstRowSelected="false" DelimiterCharacters="," ShowOnlyCurrentWordInCompletionListItem="true" ></sur:AutoCompleteExtender> 
     </div> 
    </div> 

他們在我的本地主機上顯示列表項時正常工作。一旦我部署到測試環境中,Chrome瀏覽器上顯示的列表項就沒有問題,但在IE上,第二個列表項因其下方的文本框位於第二個列表項的位置而丟失。第二個文本框出現在第一個文本框autocompleteextender的第二個列表項的位置。在附加的圖像中,列表項「測試2」在IE上丟失,然而第二個文本框出現在它的位置。任何人都可以請幫忙。

在此先感謝。 images of chrome and IE

回答

0

我已經得到了它寫在web.config中的下列解決。 IE 11的上部署的版本這是不合對IIS7

<httpProtocol> 
     <customHeaders> 
     <add name="X-UA-Compatible" value="IE=EmulateIE8" /> 
     </customHeaders> 
    </httpProtocol> 

這工作正常我的機器上。但是,一旦我部署到現場,它不適用於某些機器。當我按下F12時,它出現的錯誤是'jquery not defined'。自動填充文本框工作正常,但頁面上有兩個jquery日曆日曆不工作,用戶無法提交頁面。 在配置中使用上面的代碼,它在一些機器上工作正常,但在其他機器上卻無法正常工作(它們無法顯示日期日曆並且無法提交)。如果我刪除上面的代碼,它的正常工作在某些機器上,但不能在其他人(他們不能看到自動填充文本框中列出的第二項)

0

這是由於緩存的問題。刪除臨時文件和瀏覽歷史和它的備份和在web.config中與下面的代碼運行

<httpProtocol> 
     <customHeaders> 
     <add name="X-UA-Compatible" value="IE=EmulateIE8" /> 
     </customHeaders> 
    </httpProtocol>