Retrieve variable from PHP file on remote server.
Posted: Tue Jul 21, 2009 11:47 pm
Been writing a PHP software that I am almost done with.
I need to test the licence to ensure that they only use the software on one domain.
I have everything built on both ends, but am having problems with getting a variable from the remote script to do this. I have been racking my brain for hours.
So, here is the setup. On my main domain I have a php script that checks the Db to see if the receipt number and domain are already regstered. There are three conditions
1. Receipt or URL doesn't exsist = $status = added
2. Receipt Exsists but URL doesn't match = $status = confirmed
3. Any other condition = $status = used
It works great but now I need to pull that variable from another server. I have tried an include, file_get_contents but can't seem to echo $status.
Any thoughts?
I already realize the security risks here and will be protection with ION Cube
I need to test the licence to ensure that they only use the software on one domain.
I have everything built on both ends, but am having problems with getting a variable from the remote script to do this. I have been racking my brain for hours.
So, here is the setup. On my main domain I have a php script that checks the Db to see if the receipt number and domain are already regstered. There are three conditions
1. Receipt or URL doesn't exsist = $status = added
2. Receipt Exsists but URL doesn't match = $status = confirmed
3. Any other condition = $status = used
It works great but now I need to pull that variable from another server. I have tried an include, file_get_contents but can't seem to echo $status.
Any thoughts?
I already realize the security risks here and will be protection with ION Cube