Search code examples
web-scrapingphantomjsweb-crawlercasperjs

Target jsp form in casperjs


Casperjs quickstart google search code:

this.fill('form[action="/search"]', { q: 'google search' }, true);

How can I target this form in casperjs?

enter image description here


Solution

  • You need to use fillSelectors() function:

    this.fillSelectors('form#frm_one', {q: 'google search'}, true);