Home > other >  How to realize the python simulation login this web site
How to realize the python simulation login this web site

Time:10-09

Password is not 1111 1111 can write look at first, I'm stuck in the view state that several parameters on the

CodePudding user response:

You send the wrong place

CodePudding user response:

Can use the python library of selenium to simulate the login

CodePudding user response:

Use the get method first get to that a few view state, hair post when the login request

CodePudding user response:

Give you an example, the value to replace the
 the from simplified_scrapy. Simplified_doc import SimplifiedDoc 
The from simplified_scrapy. Request the import the req
Url='http://'
HTML=the req. Get (url)
LST=SimplifiedDoc (HTML). GetElementByTag (' form '). GetElementsByTag (' input ')
The req. Post (url, "__VIEWSTATE={} & amp; __EVENTVALIDATTION={} & amp; Account={} & amp; The UserName={} & amp; UserPass={} & amp; ButLogin=login ". The format (
LST [0] value, LST [1]. The value of LST [2]. The value of 'name', 'the PWD'
), {' the content-type: 'application/x - WWW - form - urlencoded'})
  • Related