0

We are looking for Javascript API to screen scrape page flow, including button click. If it were on server side, WebDriver of Selenium would have been a great choice, but we want the screen scraping to run on the client browser. The screens to be scrapped is a transaction in itself (login to third party website, transaction step 1, step 2 and then final confirmation). Any javascript API available?

AFAIK, both nodeJS and phantom JS don't have capability to click a button from the scrapped page.

thanks in advance, abbas

2 Answers 2

1

Webdriver is an HTTP based protocol, something that every browser speaks, so it is possible to control one browser from another. I've written a tutorial some weeks ago on that topic here

Sign up to request clarification or add additional context in comments.

Comments

0

I recently ran into DalekJS (http://dalekjs.com/docs/actions.html) which allows for taking screenshots of pages and clicking on the elements as well. I think it even supports multiple browsers -- although they have to be installed (http://dalekjs.com/pages/documentation.html#browsers).

here is the sample code directly from the link:

 test.open('http://doctorwhotv.co.uk/')
 .assert.text('#nav').is('Navigation')
 .assert.visible('#nav')
 .assert.attr('#nav', 'data-nav', 'true')
 .click('#nav')
 .done();

2 Comments

But the problem with Dalekjs is that it needs to run with a dalek framework. We require some tool (eg. js file) that we can bundle inside our webpage and runs in the browser.
I'm not sure then. I'll look harder when I get the chance.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.