Sam’s Whois Class

The “/samswhois/samswhois.class.php” file is at the heart of Sams Whois. It provides all the low-level functions including parsing the server config file, doing the whois lookup, caching results, cleaning and hilighting the whois data.

In most cases you will not need to touch this file or use any of its functions directly as the “/samswhois/samswhois.inc.php” include file handles all this for you.

A brief outline of the main user functions of this class are listed here; for further information on how to use it, see the “/samswhois/samswhois.inc.php” file.

The code snippet below illustrates basic usage of the SamsWhois class to set which tlds to use, output a list of these tlds to the browser, lookup a domain and display the results with cleaning and hilighting: