python - Need to store values from URL then send this values using post method -


i need store values method send values using post method in form.

how can that? possible?

i values method , works fine, when try use payload in post goes wrong because payload dict doesnt exist in post

if request.method == 'get':                 payload = {                     "sessid": request.get['sessid'],                     "username": request.get['username'],                     "sessionlifetime": session_timeout,                     "idletimeout": idle_timeout,                 }  if request.method == 'post':     logic payload     requests.post(url,payload) 

thanks.

when getting url data can parsed uri. when posting url data must parsed headers.

usually find posted data in 'x-www-form-urlencoded' header


Comments

Popular posts from this blog

Is there a better way to structure post methods in Class Based Views -

reflection - How to access the object-members of an object declaration in kotlin -

php - Doctrine Query Builder Error on Join: [Syntax Error] line 0, col 87: Error: Expected Literal, got 'JOIN' -