I'm using casper.evaluate() to get an array of data from within the page. However it seems to fail to return an array (whereas returning strings work flawlessly). What might be the issue?
For clarification: the code in evaluate is:
function(){
return $('#id a').map(function(i, e) {
return $(e).attr('href');
}).get();
}
The .get() at the end of the call is meant to get an array instead of a jQuery object. BTW, I'm sure jQuery is available in the page.