mardi 18 octobre 2016

CasperJS / PhantomJS not detecting Twitter iFrame embed

I'm a newbie to using CasperJS and PhantomJS and have an existing script that successfully detects DOM elements using the 'this.exists()' function, e.g.

var grid = this.exists('div.grid');

However I am attempting to detect a Twitter User Timeline feed embed (an iframe), but the above function doesn't appear to detect the <iframe> tag. I'm unsure if this is due to the fact this is an embed of Twitter's feed, but the is hardcoded into the page?

I have looked at alternatives methods of detection, for example detecting the loading of Twitter's external resources, but I believe a simpler solution should be possible?

Aucun commentaire:

Enregistrer un commentaire