Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

PHPBuilder.com:
PHP Scripts for Interacting with Networks
Dec 15, 2010 @ 19:49:31

On PHPBuilder.com there's a new tutorial showing you some of the PHP functions that you can use to interact with the network surrounding (and even vaguely related to) your application.

PHP has a great many tools for interacting with a network and also with the Internet. In this article, I examine some of those tools and functions to show how exactly you can use them to make your scripts more useful in a network environment. Click here to download the accompanying source code.

They show how to use fopen to access remote sites, gethostbyname and gethostbyaddr for DNS resolution, getprotobynumber to check the port number for a TCP/IP type and quite a few more. This also includes a brief look at the PEAR Net_Whois package. You can download the examples if you'd like to just jump into the code.

tagged: network interaction tutorial tcpip socket dns

Link:


Trending Topics: