I'm trying to see if my list already has a specific user in it. I should get "match found" printed out but I don't. I thought the problem was in my php-file so i created a text file with the same contents but it still doesn't find the match.
import urllib2
server = "10.20.68.235"
var = "patrik"
file = urllib2.urlopen("http://"+server+"/list-text.php")
for line in file:
if line == var:
print "match found"
print line,
print "done"
Here is the output im getting:
someguy
user
patrik
juniper
ftpsecure
momeunier
done