= (Socket) listSockets[listSockets. Count-1] ; String streamData = " " ; String fileName = " " ; String [] input ; Fundamentals of EMS, NMS and OSS/BSS StreamReader reader; NetworkStream networkStream = new NetworkStream (socketHandler) ; reader = new StreamReader (networkStream) ; streamData = reader.ReadLine() i input = streamData.Split (" " ToCharArray ( ) ) ; // The input line is assumed to be: GET <some URL path> HTTP/1.1 // Parse the filename using input // Add the HTTP root path fileName = path + fileName FileStream fs = new FileStream fileName, FileMode. OpenOrCreate) ; fs. Seek (0, SeekOrigin.Begin) ; byte [] fileContents = new byte [fs. Length] i fs. Read (fileContents, 0, (int) fs. Length) ; fs. Close () ; // Modify fileContents to include HTTP header. socketHandler.Send (fileContents) ; socketHandler.Close( ( ) ; 5. To test the server: Create an HTML page. Save the page as index.htm at HTTP root path. Run the server. Open a browser and type in http://localhost:9080. Localhost should be replaced by the IP address of the server when server is running on a dif- ferent machine from where the browser is launched. The index.htm page is displayed. 28.5 Conclusion In a typical client-server model, each application has its own client program and had to be separately installed on the client machine. Only after the client applica- tion is installed on the machine will the user interface be available. Any upgrade of client application would require an upgrade of solution running on individual user workstation also. This resulted in a huge maintenance cost and decreased produc- tivity. Also with the wide spread use of Internet, there was an increased demand for making applications available anytime and anywhere. Web Communication The advantage of Web applications is that it uses a generic client application. Web documents are written in a standard format such as HTML that can be pre- sented on any Web browser and does not require a specific client application. So any change in the server will not require an upgrad