Z-index in jQuery dialog. Autosuggest list not displayed properly

前端 未结 4 1980
囚心锁ツ
囚心锁ツ 2021-01-15 03:08

I have a problem displaying the autosuggest box inside a jQuery dialog. The auto suggest list is displayed under the dialog no matter what. I have tried setting up the z-ind

4条回答
  •  星月不相逢
    2021-01-15 03:40

    This is what you can do:

    $("#txtTagAdd").autoSuggest(data.items, {
                            asHtmlID:"tagg",
                            selectedItemProp: "name",
                            searchObjProps: "name",
                            selectionLimit:4,
                            limitText: "Only 4 tags unique tags allowed for each suggestion",
                 resultsComplete: function(){
                     var h = $('ul.as-list').innerHeight() + 20;
                     $('div.as-results').css({"height": h + "px"});
                 }
    });
    

提交回复
热议问题