[BangPypers] how to read remote uploads

Noufal Ibrahim noufal at gmail.com
Mon Oct 18 14:11:27 CEST 2010


On Mon, Oct 18 2010, Kenneth Gonsalves wrote:


[...]

> the gps program sends the info with a php url - I need to collect the
> info and massage it before sending it to the webserver for display. So
> I need a small python program to listen on that port and collect
> whatever comes (is it socket programming or something like that?)

>From your description, it sounds like a you need a simple program that
listens on this port which will accept anything that comes in, process
it and then send it to your actual web application. So, yes. this is a
program that uses a socket.

This is a simple proxy that will listen on a local port and then use
some HTTP client library to send it to the web application.

The pages in the Python docs which discuss 'SocketServer' has a small
example which you can alter to suit your needs I think.

-- 
~noufal
http://nibrahim.net.in


More information about the BangPypers mailing list