alexscheelmeyer / node-phantom

bridge to PhantomJS from Node.js
317 stars 117 forks source link

node-phantom.js options.parameters #48

Closed uittilla closed 11 years ago

uittilla commented 11 years ago

When passing params into phantom.create it throws an error. Its a slight overlook but here it is. Sorry to all if its already been reported.

line 24 in node-phantom.js

for(var parm in options.parameters) { --> args.push('--' + option + '=' + options.parameters[parm]); }

Works when i change it to 'parm'

for(var parm in options.parameters) { args.push('--' + parm + '=' + options.parameters[parm]); }

Cheers

cedmax commented 11 years ago

it seems to be already fixed in the source, not pushed to npm though

cedmax commented 11 years ago

update:

I solved adding to my package.json

"node-phantom": "git://github.com/alexscheelmeyer/node-phantom.git#7b82108a45ad22a3ca38f1383593e66d5369d574",
uittilla commented 11 years ago

Many thanks

Nice lib BTW :) very usefull

alexscheelmeyer commented 11 years ago

This is now pushed to npm so no reasons for workarounds. Sorry for the delay.