kansaschuck Posted March 12, 2008 Share Posted March 12, 2008 Hello all. I'm stuck on what I would think would be a very simple subject. So most likely there is some simple concept I'm not understanding. I have a program that is issuing a HTTP POST (on laptop)to a my website(ISP). On the website I understand that I need to build a program that execute and captures that data from the POST (I'd like to do it in PHP) . On the internet I'm finding plenty of examples of how to POST. Hundreds of them. But finding a good example of how to capture the data I'm not finding. I'm looking for information on options, parms, examples for the receiving PHP program. So maybe I don't know what it is called and I'm searching wrong, or maybe there are few because nobody does it that way. I do see examples of POST to forms. I don't think that's what I want (I could be wrong). Currently I was looking to capture, (via the PHP program), the data from a simple little Perl program listed below. This is the Laptop program that is issuing the post. I'm looking to develop the code for the PHP program at receiving HTTP server (my website). use LWP::UserAgent; my $ua = new LWP::UserAgent; my $req = new HTTP::Request 'POST','http://mysite.com/x.php'; $req->content_type('application/x-www-form-urlencoded'); $req->content('What are you doing, Dave?'); my $res = $ua->request($req); print $res->as_string; Quote Link to comment Share on other sites More sharing options...
Demonic Posted March 12, 2008 Share Posted March 12, 2008 What language is that? Quote Link to comment Share on other sites More sharing options...
kansaschuck Posted March 12, 2008 Author Share Posted March 12, 2008 "the data from a simple little Perl program listed below." Perl (shown above) is POSTing to (a future) PHP program. From what I've learned in my research since I've opened this question is since I may not understand the sending of data in the 'Content' area. How the data is packaged up on one end for PHP to extract on the other. Quote Link to comment Share on other sites More sharing options...
Northern Flame Posted March 12, 2008 Share Posted March 12, 2008 look up $_POST Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.