Jump to content

[SOLVED] make a http request behind the scenes - query an API


fwd4

Recommended Posts

Quick question (I hope)... When someone is redirected to my site I am given a user ID and a token parameter on the URL like so:

 

http://www.mysite.com/download.php?userID=12345&token=ABCDEF

 

I'm picking the user ID and token parameters up from the URL using GET. Once I have them I need to check the validity with a 3rd party API in the format:

 

http://xml.checker.com/tokencheck.asp?t=ABCDEF&u=12345

 

In return I get a simple XML output of either true or false:

 

<?xml version="1.0"?>

<response success="false">

</response>

 

My question is how do I make the make the HTTP request to the tokencheck.asp and parse back the simple XML? I'm pretty new to all of this but enjoying it immensely!

 

Thanks in advance

 

FWD4

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.