T
tedpottel
Hi,
I'm trying to post data to a short test script in php I wrote.
The python code to do the post is
import httplib
#server address
conn = httplib.HTTPConnection("localhost")
#file location
conn.request("POST", "/programming/bots/test.php","&ted=fred")
r1 = conn.getresponse()
print r1.status, r1.reason
data1 = r1.read()
print data1
conn.close()
print "new ok"
The PHP script is
print"hello <br>";
print $_POST["ted"];
Ted post
I'm trying to post data to a short test script in php I wrote.
The python code to do the post is
import httplib
#server address
conn = httplib.HTTPConnection("localhost")
#file location
conn.request("POST", "/programming/bots/test.php","&ted=fred")
r1 = conn.getresponse()
print r1.status, r1.reason
data1 = r1.read()
print data1
conn.close()
print "new ok"
The PHP script is
print"hello <br>";
print $_POST["ted"];
Ted post