O'Reilly logo

Webmaster in a Nutshell, Second Edition by Robert Eckstein, Stephen Spainhour

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Miscellaneous Functions

DNS/Networking Functions

int checkdnsrr(string host [, string type])

Check DNS records corresponding to a given Internet hostname or IP address

int fsockopen(string hostname, int port [, int errno [, string errstr]])

Open Internet or Unix domain socket connection

string gethostbyaddr(string ip_address)

Get the Internet hostname corresponding to a given IP address

string gethostbyname(string hostname)

Get the IP address corresponding to a given Internet hostname

array gethostbynamel(string hostname)

Return a list of IP addresses that a given hostname resolves to

int getmxrr(string hostname, array mxhosts [, array weight])

Get MX records corresponding to a given Internet hostname

set_socket_blocking(int socket descriptor, int mode)

Set blocking/non-blocking mode on a socket

Program Execution Functions

escapeshellcmd(string command)

Escape shell metacharacters

int exec(string command [, array output [, int return_value]])

Execute an external program

int passthru(string command [, int return_value])

Execute an external program and display raw output

int system(string command [, int return_value])

Execute an external program and display output

Random Number Functions

int getrandmax(void)

Return the maximum value a random number can have

int mt_getrandmax(void)

Return the maximum value a random number from Mersenne Twister can have

int mt_rand([int min, int max])

Return a random number from Mersenne Twister

void mt_srand(int seed)

Seed Mersenne Twister random number ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required