Webpage data extraction automation using python and selenium webdriver [closed]

2024/10/5 19:38:43

May I know to have it work properly what are the software i need to install in my PC?

UPDATE

Error i was getting is this:

Getting this error when running pip install -U selenium. Mid way through the script, it gets the following SyntaxError:

    Traceback (most recent call last):File "<string>", line 14, in <module>File "C:\Python32\Scripts\build\rdflib\setup.py", line 6, in <module>from rdflib import __version__File "rdflib\__init__.py", line 64, in <module>from rdflib.term import URIRef, BNode, Literal, VariableFile "rdflib\term.py", line 367except TypeError, te:^SyntaxError: invalid syntaxComplete output from command python setup.py egg_info:Traceback (most recent call last):File "<string>", line 14, in <module>File "C:\Python32\Scripts\build\rdflib\setup.py", line 6, in <module>from rdflib import __version__File "rdflib\__init__.py", line 64, in <module>from rdflib.term import URIRef, BNode, Literal, VariableFile "rdflib\term.py", line 367except TypeError, te:^SyntaxError: invalid syntax----------------------------------------
Command python setup.py egg_info failed with error code 1

Thanks,

Answer

All you need is python here and selenium here.

Windows 7 or another system:

To install selenium, extract tr.gz file, cd into the directory and then python setup.py install.

Or you could use pip like this:

pip install -U selenium


Specifically for linux, use

$ sudo apt-get install python-pip
$ sudo pip install selenium

Installing on windows:

Download selenium from here and setuptools from here. Extract them anywhere you chose, in this case I extracted them inc:\Users\User\Desktop\...

Cd into the directory and then do python setup.py install if it says it cannot find python try c:\Python27\python.exe setup.py install to first install setup tools: enter image description here

Next cd into the seleneium directory and do python setup.py install: enter image description here

If everything goes well there should not be any errors and you are ready to use selenium. enter image description here

https://en.xdnf.cn/q/120647.html

Related Q&A

Asking the user if they want to play again [duplicate]

This question already has answers here:Ask the user if they want to repeat the same task again(2 answers)Closed 5 years ago.Basically its a guessing game and I have literally all the code except for th…

IF statement (checking for a string in a list) behave weirdly [duplicate]

This question already has answers here:How to test multiple variables for equality against a single value?(31 answers)Closed 10 years ago.This will probably be a dumb question, but why does this piece…

filteration in txt file in python

I have too many lines like this:>ENSG00000100206|ENST00000216024|DMC1|2371|38568257;38570043|38568289;38570286 CTCAGACGTCGGGCCGACGCAAGGCCACGCGCGCGAACACACAGGTGCGGCCCCGGGCCA CACGCACACCGTACAC >ENSG0…

Count the number of times elements in a numpy array consecutively satisfy a condition

I have a numpy array as follows:import numpy as np a = np.array([1, 4, 2, 6, 4, 4, 6, 2, 7, 6, 2, 8, 9, 3, 6, 3, 4, 4, 5, 8])and a constant number b=6I am searching for a number c which is defined by t…

Finding the index of the first repeating item in an array in python

I was solving an arrays problem from GFG, where we need to find the index of the first repeating element. The question is as follows: Given an array arr[] of size n, find the first repeating element. T…

how to check str int list and tuple? [closed]

Its difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying thi…

How to take out numbers and add them together in python [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.Questions asking for code must demonstrate a minimal understanding of the problem being solved. Incl…

Populate mysql table with random data in python

How can create a mysql table in python and then populate it with random data.I want around 10000 rows and integer values will do work.

I want to change a tuple into string without joining it in python. How could I do that? [duplicate]

This question already has answers here:Convert a list to a string without join(5 answers)Closed 3 years ago.For Example: I want to change t=(a, b, c) to s=a, b, c

Convert several YAML files to CSV

I am very new to Python and have several YAML files that I need to convert into csv. These are notes, comments and emails that came from our CRM (Highrise). I ONLY need the Notes and Comments, not the …