PhantomJS plugin: Added optional timeout.
Closes #415.