Is it possible to do as per the subject? The webpage I am working with sends a file in the response to myself and I can detect this, however the url it provides is to the base page. So I cannot download the file by accessing the resource.url portion of the metadata. Is there a simple way (or any way) of getting the raw response (or something)? I can see it coming through Fiddler just fine. Code is below.
casper.on('resource.received', function (resource) {
var url, file;
url = resource.url;
file = "stats.csv";
//this.echo(JSON.stringify(response));
if (resource.contentType.indexOf("ms-excel") > -1){
//this.download(url, file, "GET");
this.echo(JSON.stringify(resource));
//this.echo(this.page.content);
}
});