I have a Select element which options are being populated dynamically from a database. However, when I attempt to collect these in an array using the standard javascript or jquery methods I come up with a blank... it's as if there are no "options" in my element - except when I do a right-click / "View Source" and inspect it there are options there.
Anyone have a clue about what's going on and what I can do to capture those 'hidden' options?
Attempted solution:
var ProdOptions = new Array;
$("#dataset.recordids.Products option").each ( function() {
ProdOptions.push ( $(this).val() );
});
For clarity: The element id="dataset.recordids.Products". The code is being called out after the page is loaded and document ready (in fact I've even put it into a button to test the possibility that it was happening before the data was populating - no luck).