i have this situation where in i am uploading files to a server using Python. here is my python script. this uses apache2 certified requests library
def Upload(self):
Url = 'http://x.php'
Payload = {
'Location' : self.Location,
'Version' : self.Version,
'Variant' : self.Variant,
}
#employing requests
File = {'file' : ('TestFile', open(self.Location, 'rb'))}
response = requests.post(Url, files=File, data=Payload)
The data is received by an apache2 server running on ubuntu machine. I would want to know how to access the sent file from the PHP code and save it in the desired location. Can you please suggest the way to achieve this.
Is there any way like HTTP, where i can specify the that this is like so, i can access using $_FILE["TestFile"]
Please help -sreekanth