S=dwmctemp
data=https://bbs.csdn.net/topics/urllib.parse.quote (s)
Url=url + data
Token='5426 fxb1 ed5 4-6 XXX - b2da - 49 cxxxxxc35b'
Headers={" Authorization ": the token}
Print (headers)
The req=requests. Get (url=url, headers=headers)
Print (the req. Json ())
Eye to check the GET data. Units of the network is a network, you must use a proxy access network, but with a lot of acting ways cannot access network, where teachers help to look at the question,
Behind the other two have no reaction, a kind of network management have no reaction, as if to say what does involve cross-domain
# OS. Environ [' http_proxy]='http://64.209.XX.127:808'
# OS. Environ [' https_proxy]='https://64.209.XX.127:808'
Ph=# urlreq. ProxyHandler ({' HTTPS: 'http://64.209.XX.127:808'})
# oper=urlreq. Build_opener (ph)
# urlreq. Install_opener (oper)
# proxies={' HTTP: 'http://64.209.XX.127:808', 'HTTPS:' https://64.209.XX.127:808 '}
#, [Access - Control - Allow - "Origin"]="*", [] "Access - Control - Allow - the Methods"="POST, GET, OPTIONS," [" Access - Control - Allow - Headers "]='*'
The req=requests. Get (url=url, headers=headers, proxies=proxies)
CodePudding user response:
I am call PYTHON with ASPCodePudding user response:
Why use the req=requests. Get (url=url, headers=headers, proxies=proxies)Displays
Requests. The get () to specify request broker when the Web server as a gateway or proxy server received an invalid response, I am using Web call py, whether because of cross-domain problem, snow answer genuflect is begged
CodePudding user response:
Why use the req=requests. Get (url=url, headers=headers, proxies=proxies)Displays
Requests. The get () to specify request broker when the Web server as a gateway or proxy server received an invalid response, I am using Web call py, whether because of cross-domain problem, snow answer genuflect is begged