All,
I have a variable like this:
var get_form_id = formid.split('_');
var vendor_id = get_form_id[1];
I would like to use this in a selector then because some of my divs are variable. So for example, I’d like to fade in a div like this:
$("#star_loader").fadeIn(function()
but I want to use my variable. I tried to do something like:
$("#star_loader"+vendor_id).fadeIn(function()
That didn’t work though. How can I use this correctly? Thanks for the advice.
That should work without problems. See this jsfiddle.