colszowka / phantomjs-gem

Phantomjs via Rubygems: Auto-install phantomjs on demand for current platform. Comes with poltergeist integration.
Other
222 stars 104 forks source link

How to pass command line options to the javascript file? #63

Closed deepsh91 closed 8 years ago

deepsh91 commented 8 years ago

While calling Phantomjs.run('path_to_js_file.js', 'arg'), I also want to set up command line options, such as --ignore-ssl-errors = true. How to do this?

deepsh91 commented 8 years ago

Found answer: Phantomjs.run('--ignore-ssl-errors=true', 'path_to_js_file.js', 'arg')