websemantics / Image-Select

Image Select is an extension of Chosen, a jQuery plugin that makes long, unwieldy select boxes much more user-friendly. It provides image support for Single and Multi select HTML tags.
http://websemantics.github.io/Image-Select
MIT License
148 stars 44 forks source link

Problems adding option to select #35

Open tribemax opened 7 years ago

tribemax commented 7 years ago

Select:

``

Create a .js file with the following code:

` (function ($) { $.get("/SigaBrokers.xml", function (Broker) { $(Broker).find("BD").each(function () {

        var ID = $(this).attr('ID');
        var nombre = $(this).attr('nombre');
        var WebSpeed = $(this).attr('WebSpeed');
        var Hosting = $(this).attr('Hosting');
        var imagen = $(this).attr('imagen');
        var activo = $(this).attr('activo');

        var xmlurl = Hosting + WebSpeed + "SigaNet.p?userwin=usuariowin&opc=4"

        $('#selectcias').append('<option data-img-src="/Images/Logos/' + imagen + '" value="' + ID + '">' + nombre + '</option>');
    });
});

})(jQuery); `

Not adding new options to select, shows me the object without problems. Previously I had the jquery code inside the page and loaded the options but I did not show them, I could see it in the chrome debugger, but clicking on the select did not show me anything. I hope you can help me.

websemantics commented 7 years ago

Trying to catch up with issues, did you manage to solve this?