BigBadVoodoo
BigBadVoodoo

Reputation: 23

Transparent drop down list when using jquery autocomplete

I'm trying to use autocomplete from jquery-ui but the drop down list with suggestions is transparent so the text blends in with the page behind it. This is what the script looks like:

var createAutocomplete = function () {
        var $input = $(this);
        var options = {
            source: $input.attr("data-otf-autocomplete")
        };

        $input.autocomplete(options);
    };

$("input[data-otf-autocomplete]").each(createAutocomplete);

I would post an example picture if i could. Anyone know what might be causing this problem? Thanks!

Upvotes: 0

Views: 1411

Answers (2)

PhilSparks
PhilSparks

Reputation: 1

Just add a link to one of the built-in themes that comes with JQuery UI.

Upvotes: 0

freshbm
freshbm

Reputation: 5632

You need to include Jquery UI CSS file in your page before js script. Css file should be inside your zip file when you downloaded jqueryUI from their site.

<link rel="stylesheet" href="jquery-ui.min.css">
<script src="jquery-ui.min.js"></script>

Upvotes: 1

Related Questions