我该如何解决这个问题?
C:\ WINDOWS \ system32> phantomjs phantomjs> ^ C
>>> from selenium import webdriver
>>> dr=webdriver.phantomjs()
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: 'module' object is not callable
>>> driver =
webdriver.phantomjs(executable_path='D:\soft\foldsoft\phantomjs\phantomjs-2.1.1-windows\bin\phantojs')
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: 'module' object is not callable
>>>
答案 0 :(得分:0)
您需要大写PhantomJS
dr= webdriver.PhantomJS()