var test1; $(document).ready(function () { test1 = $(\"#test1ID\").jQueryPlugin(); }); var test2; $(document).ready(function () { test2 = $(\"#test2ID\").jQuery
Have you tried
$('#' + theArrayOfStrings[i]).foo();
Have a look at API/1.3/Selectors