Liceincing Check

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
User avatar
Mr Tech
Forum Contributor
Posts: 424
Joined: Tue Aug 10, 2004 3:08 am

Liceincing Check

Post by Mr Tech »

Hi there,

I'm wanting to set up a script where if the liceince number is incorrect, it won't work.

How do I check whether a liceince is valid from a remote server? (E.g: their website connects to my website and my website checks if the licience is valid. If not it sends back a $ so I can stop the script from working)

Thanks

Ben
timvw
DevNet Master
Posts: 4897
Joined: Mon Jan 19, 2004 11:11 pm
Location: Leuven, Belgium

Post by timvw »

what exactly is your problem? because you seem to have the logic right...
User avatar
Mr Tech
Forum Contributor
Posts: 424
Joined: Tue Aug 10, 2004 3:08 am

Post by Mr Tech »

Yes but I don't have any code... Don't know where to start...
User avatar
phpScott
DevNet Resident
Posts: 1206
Joined: Wed Oct 09, 2002 6:51 pm
Location: Keele, U.K.

Post by phpScott »

you got the logic.

1)have remote server access your site with their liscence.
2)have your site check against a db most like to see if they have a valid liscence.
2a)if it is valid then send something back that will activate the rest of the script.
2b)if not return back a different code that will stop the script from working or you could be really mean and even maybe delete the script.

the trouble will be is if they also have direct access to your script then any programmer will probably be able to code in a work around.

the other option is for the script to reside on your server and the have to include it so they don't have direct access to it but depending on the popularity of your script then you could run into bandwith issues.
qads
DevNet Resident
Posts: 1199
Joined: Tue Apr 23, 2002 10:02 am
Location: Brisbane

Post by qads »

If your server is down, you gona have lot of angry people outside your door :roll:.

You might wanna use a script encoding program, such as zend, there are cheaper ones out there which have built in licence system (sort of), checkout [google]guardian[/google].
Post Reply