Python Forum
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Requests login failure
#5
Hello, i had put the wrong code as the working one..
here's the code that works..

#Trying selenium

from selenium import webdriver
from bs4 import BeautifulSoup
import time
from urllib.request import urlopen
from selenium.webdriver.common.action_chains import ActionChains

browser = webdriver.Firefox()
url = 'https://python-forum.io/member.php?action=login'
browser.get(url)
browser.find_element_by_name('username').send_keys("test")
browser.find_element_by_name('password').send_keys("*********")
time.sleep(5)
button = browser.find_elements_by_class_name('button')[2]
# button.send_keys(Keys.PAGE_DOWN)
button.click()
time.sleep(5)
  
goUrl="https://python-forum.io/usercp.php"
browser.get(goUrl)
Inputs welcome, especially to make this work with requests
Reply


Messages In This Thread
Requests login failure - by test - Sep-09-2018, 06:34 AM
RE: Requests login failure - by test - Sep-09-2018, 03:35 PM
RE: Requests login failure - by test - Sep-09-2018, 05:05 PM
RE: Requests login failure - by test - Sep-10-2018, 02:36 AM
RE: Requests login failure - by test - Sep-10-2018, 03:52 PM
RE: Requests login failure - by snippsat - Sep-10-2018, 06:01 PM
RE: Requests login failure - by test - Sep-11-2018, 01:43 AM
RE: Requests login failure - by test - Sep-13-2018, 02:20 AM
RE: Requests login failure - by test - Sep-13-2018, 03:35 AM
RE: Requests login failure - by snippsat - Sep-13-2018, 07:58 AM
RE: Requests login failure - by test - Sep-13-2018, 08:48 AM

Possibly Related Threads…
Thread Author Replies Views Last Post
  POST requests - different requests return the same response Default_001 3 1,970 Mar-10-2022, 11:26 PM
Last Post: Default_001
  How to perform a successful login(signin) through Requests in Python Kalet 1 2,366 Apr-24-2020, 01:44 AM
Last Post: Larz60+
  HOWTO? Login DSL Modem with Python Requests: need Click "Apply" Button Webtest 4 8,542 Aug-20-2019, 04:03 PM
Last Post: johnmina
  Using python requests module and BS4 to login on an Wordpress based website apollo 1 9,462 Feb-06-2018, 01:31 AM
Last Post: metulburr

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020