PHP Classes

Spotted a small issue

Recommend this page to a friend!

      License management class  >  All threads  >  Spotted a small issue  >  (Un) Subscribe thread alerts  
Subject:Spotted a small issue
Summary:Class won't work in cli mode...
Author:Andrei Orghici
Date:2011-02-02 07:59:02

  1. Spotted a small issue   Reply   Report abuse  
Picture of Andrei Orghici Andrei Orghici - 2011-02-02 07:59:04
As you get host name and host ip when validating a serial number this class won't work in cli mode, which can be bad as you might want to validate a serial number in background process or in an api call.

// get host name
function get_host_name()
return $_SERVER['HTTP_HOST'];
// get host ip
function get_ip_address()

You could add setters for ip and host names.