RazorX -> Tutorials
Overview: This tutorial shows you how to easily install and set-up Microsoft's IIS 5.1 web server on the Windows XP Professional operating system for use as a local or personal web server (web development environment) to process document requests. It also shows you how to configure the document serving order (index.htm, index.html, default.htm, etc.) and how to complete your installation with a basic ASP test script.
Also if you are interested in setting up PHP to run on your IIS server, a link to PHP installation and a script test
is available at the end.
Which version of the XP operating system do I need to install IIS and why should I install IIS?


|
IIS is Microsoft's acronym for Internet Information Server. IIS is a suite of tools and services for creating, managing, and deploying a web server. The version that ships with XP Pro is meant to be used for personal development or for up to ten people using it as an Intranet, for file sharing, printers, etc. according to the Microsoft ULA for XP Pro. As a web developer you need a web server for your development environment. You can develop with a remotely hosted server, but it's much faster, and safer to create applications and code locally. Web-based scripting can be created in programming languages such as: ASP, .NET, PERL, PHP, Python, JSP, etc. With the appropriate document extension and page delimiters, the server will recognize and parse (run through) the programming code written within that particular document and perform the directed instructions from the code. For this type of processing, also called server-side processing, you need a web server. Since IIS 5.1 is not a full scale server, the limited functionality of its built-in IIS will prevent you from doing advanced functions that you can only do with a full scale server like Windows Server 2003.
|
If I have the XP Home Edition, can I install IIS using it?
 |
The answer is no. The XP Home Edition does not ship with the IIS components. You will need the XP Professional Edition to set up and utilize the IIS 5.1 server.
|
Let's get started installing IIS:
The Internet Information Server (IIS) is not installed by default with a standard Windows XP Pro installation. You will need your original Windows XP Pro CD when prompted to install IIS, and you must be able to log in under a user account that has administrator privileges. Go to Control Panel -> Add or Remove Programs ->
Add/Remove Windows Components.
At the Windows Components panel, select the Internet Information Servicess (IIS)
checkbox, and then hit Next.

After you select the Next button, unless XP was installed from a network, you will be prompted for the original Windows XP Professional CD. Insert the CD and continue.

Once installation has completed, point a browser to http://localhost or http://127.0.0.1 With a successful install, you should see the page below... easy cheesy wasn't it? Rock'in! Way ta go playa! You can also access your server home page if you know your computer's IP address or computer name. From a Command Prompt you can type ipconfig or ping localhost to find out that info if you are curious. Before we conclude, we need to do a few more things. Next we need to know how to configure and control the default document serving order and create our own server home page.
Scroll on down for this next step.

Let's configure the default document serving order and create our own server home page. Go to Control Panel -> Administrative Tools -> Internet Information Services. Expand the local computer directory, then right click on Default Web Site and select Properties from the cascade.

After the Properties panel opens, select the Documents tab. In the Default Document listing box use the Add button to add index.htm and index.html. Now use the up and down arrow buttons on the left side to reorder the listing. Place the index.htm and index.html at the top and either move down or remove the iisstart.asp listing. Make sure you remember to hit the Apply button. Now whenever you place an index.htm in any folder, the web server will know that it's the default document and if available, it will serve it first in the directory.

Using Notepad or Dreamweaver, just write a simple index.htm test document and then save it into your C:\Inetpub\wwwroot directory.
<html>
<head>
<title>Home page test</title>
</head>
<body>
<div align="center">Cool! My own server home page.</div>
</body>
</html>
With a browser navigate to http://localhost You should now see your index.htm test page.

For our last lesson we will put together a nodoubt.asp (Active Server Page) test page. Using Notepad or Dreamweaver, write the following and then save it into your C:\Inetpub\wwwroot\ directory.
<html>
<head>
<title>ASP page test</title>
</head>
<body>
<div align="center">
<% Response.Write("My ASP test page works. Were there any doubts?") %>
<br>
<br>
<% response.write(Request.ServerVariables("SERVER_SOFTWARE")) %> </div>
</body>
</html>
With a browser, navigate to http://localhost/nodoubt.asp You should now see your nodoubt.asp page. When the server sees the .asp extension, it knows to run through the test page and process any code surrounded by <% %> delimiters before releasing the page to the browser. Special note: The last version of ASP was version 3.0, and the next generation has now moved to ASP.NET, but it's still useful to understand how to use and write in ASP 3.0. Once you have a firm grasp of ASP 3.0 you can then move on to ASP.NET.

Well that's it! Now you know how to install your own IIS server, change the default document serving order, and create a server home page and basic .asp test page. It's important as a web developer to know and understand all these things, and it's much faster to develop and test your scripts and applications on a local machine rather than a remote one. You are well on your way to saving the Internet with your superior web code and flashy web skills.
|