Fitting the Application into the Network

If you came up with a plan to develop your own server in PHP (or something similar), rethink a bit. You might have gotten a bit confused with the idea that implementing a chat server means implementing a network server. This is indeed something we wanted to lead you to, but don't want you to do, as this is simply unnecessary—there's already a well-written server software available for all systems. So how about using one of the existing servers and representing our server to the network as a client? The only thing we'd have to do is to add another layer of abstraction to the network, as shown in Figure 3.4.

Figure 3.4. phpChat as an abstraction layer to the server.

The Web server will run the PHP chat ...

Get Web Application Development with PHP 4.0 now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.