Avatar of Hiro 714
Hiro 714

asked on 

Python Slenium question

I have a variable contains a list of URL.
https://abc.com/123
https://abc.com/456
https://abc.com/789

Open in new window

I want to go each URL and grab web title.
Please advise.
SeleniumPython

Avatar of undefined
Last Comment
Hiro 714
Avatar of ste5an
ste5an
Flag of Germany image

Just do it.
SOLUTION
Avatar of David H.H.Lee
David H.H.Lee
Flag of Malaysia image

Blurred text
THIS SOLUTION IS ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
Avatar of Hiro 714
Hiro 714

ASKER

thank you.
 I get this error message from jupyter notebook.

---------------------------------------------------------------------------
httperror_seek_wrapper                    Traceback (most recent call last)
<ipython-input-87-7bc310fc5cad> in <module>
      6 for x in range(len(a)):
      7  br = Browser()
----> 8  br.open(a[x])
      9  print("Website title: ")
     10  print(br.title())

~\Anaconda3\lib\site-packages\mechanize\_mechanize.py in open(self, url_or_request, data, timeout)
    255         :return: A :class:`mechanize.Response` object
    256         '''
--> 257         return self._mech_open(url_or_request, data, timeout=timeout)
    258
    259     def _mech_open(self, 
~\Anaconda3\lib\site-packages\mechanize\_mechanize.py in _mech_open(self, url, data, update_history, visit, timeout)
    311
    312         if not success:
--> 313             raise response
    314         return response
    315

httperror_seek_wrapper: HTTP Error 403: b'request disallowed by robots.txt' 

Open in new window

ASKER CERTIFIED SOLUTION
Avatar of Yujin Boby
Yujin Boby
Flag of India image

Blurred text
THIS SOLUTION IS ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
Avatar of Hiro 714
Hiro 714

ASKER

I have some website requires password and yubikey. would you advise me?

Python
Python

Python is a widely used general-purpose, high-level programming language. Its design philosophy emphasizes code readability, and its syntax allows programmers to express concepts in fewer lines of code than would be possible in other languages. Python supports multiple programming paradigms, including object-oriented, imperative and functional programming or procedural styles. It features a dynamic type system and automatic memory management and has a large and comprehensive set of standard libraries, including NumPy, SciPy, Django, PyQuery, and PyLibrary.

6K
Questions
--
Followers
--
Top Experts
Get a personalized solution from industry experts
Ask the experts
Read over 600 more reviews

TRUSTED BY

IBM logoIntel logoMicrosoft logoUbisoft logoSAP logo
Qualcomm logoCitrix Systems logoWorkday logoErnst & Young logo
High performer badgeUsers love us badge
LinkedIn logoFacebook logoX logoInstagram logoTikTok logoYouTube logo