python + selenium问题,谁能看一下,装了selenium 但是用不了 5

#coding=utf-8>>>seleniumTraceback(mostrecentcalllast):File"<pyshell#1>",line1,in<modu... # coding=utf-8>>> seleniumTraceback (most recent call last): File "<pyshell#1>", line 1, in <module> seleniumNameError: name 'selenium' is not defined>>> import selenium>>> from selenium import webdriver>>> driver = webdriver.firefox()Traceback (most recent call last):
没有装好吗
展开
 我来答
匿名用户
推荐于2018-05-15
展开全部
应该是webdriver.Firefox()吧,那个F大写吧;3.0版本的selenium调用firefox的时候好像要用的一个叫geckodriver.exe的才行,下载这个文件放到Python27\Scripts目录下就行(前提是Python27\Scripts目录在环境变量)。
推荐律师服务: 若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询

为你推荐:

下载百度知道APP,抢鲜体验
使用百度知道APP,立即抢鲜体验。你的手机镜头里或许有别人想知道的答案。
扫描二维码下载
×

类别

我们会通过消息、邮箱等方式尽快将举报结果通知您。

说明

0/200

提交
取消

辅 助

模 式