Jump to content

HTTP POST question


Buchead

Recommended Posts

Apologies if this is in the wrong thread but no sure where it should have gone (if anyone can tell me I'd appreciate it).

 

Anyway, I'm having a problem with HTTP POST. In the header no file is being specified, only the root file system. All the other times I have used this a file is specified so how can I detect the data transfer and handle the data?

 

The header:

 

POST / HTTP/1.0.  .Accept: */*..Accept-Language: en-us..Content-Type: application/x-www-form-urlencoded..Host: thesite.co.uk Content-Length: 135 Pragma: no-cache username=user&password=password

 

It's coming through port 21 on the server. Someone suggested putting some form of listening app on the port but then they countered it saying this would prevent any files being ftp'd to the server.

 

Any assistance would be greatly appreciated!

 

Thanks.

Link to comment
https://forums.phpfreaks.com/topic/250359-http-post-question/
Share on other sites

Sorry, should have said.

 

A 3rd party app is sending data to our server to update a web shop. After the username and password would be all the product information in csv format. I need to grab this data and then process it. What I'm struggling to do is grab the data. If they pointed it at a file on our server I could process it just like a form. Whether this is the right procedure I don't know, however it's how I've used HTTP POST in the past.

 

As this data is being pointed at any file I can't see how to grab it. Hopefully this makes a little more sense now!

Link to comment
https://forums.phpfreaks.com/topic/250359-http-post-question/#findComment-1284575
Share on other sites

If you already have an FTP server running on port 21 yes it will prevent uploading of files via FTP.

 

IS there particular reason your receiving the data on port 21?

 

And no, if you don't have control over Apache you will not be able to configure it to listen to an uncommon port.

Link to comment
https://forums.phpfreaks.com/topic/250359-http-post-question/#findComment-1284596
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.