+1 vote
by
There is an HTML element
<form action="/login" method="POST"><input type="hidden" name="PHPSESSID" value="16d372e503adcfdb6ed1929d1318f4fb.1585319930.52116411" /><input type="hidden" name="PHPSESSID" value="4a1c844bdf1bc00c0c02742d0aecb226.1585319930.52239339" />

how to get both values ?
I was only able to get the first one
value = soup.find_all('input', {'name': 'PHPSESSID'}).get('value')

I need to get
print(value)
print(value1)

1 Answer

0 votes
by
 
Best answer
Remove "{'name': 'PHPSESSID'}"
find_all will give you a list, loop around and get the value of each
...