Possible Permission Issue with Python Script?
"""
form= cgi.FieldStorage()
with open('p2_input.txt', 'r+') as input:
p2_weapon=str(form.getvalue("Weapon", "none"))
input.write(str(p2_weapon) + '\n')
print "<center><p>" + p2_weapon + "</p></center>"
This is surrounded in html, and is being run with Apache. The input isn't being written to the .txt and I'm wondering if this is because Apache doesn't have write permissions. How can I check this, and what would be the solution?
Posted Dec 6, 2018, 1:11 AM UTC
16