Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

handle a GET request

Status
Not open for further replies.

megmogg

Programmer
Jul 14, 2005
76
GB
Hi all

Do not know if this is possible.

I need to exchange data with another company/site.

They require me to handle their HTTP GET request and send a response back (a success or error code).

They have suggested that I should write a CGI script but I have no knowledge of this.

The example they give is:

Can I do this in PHP and return a result?

Thanks in advance
 
easily I would imagine, depends exactly what you want to do with it.

snippet:

<?php
if(isset($_GET[var1],$_GET[var2]))
{
echo "var 1 : $_GET[var1] var2: $_GET[var2]";
//...
//do whatever with them
//....
}
?>

this requires a url http(s)://yourserver/yourscript.php?var1=something&var2=else

______________________________________________________________________
There's no present like the time, they say. - Henry's Cat.
 

Thanks for the quick reply.

That is what I was think (although I am a novice PHP'er).

However, they want a response so they know I have got their data OK.

Do you know how could I do this?


 
email , smoke signal, sms , database connection.

ok so smoke signals may not be possible, but the rest can all be done.

Really need more info to formulate sensible reply.

______________________________________________________________________
There's no present like the time, they say. - Henry's Cat.
 

Thanks for the reply and know what you are saying.

From what I gather, although they are not very clear, they want a 200 response.

 

.....a http 200 response with a non-empty body......
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top