HomeASP.NET Run ASP.NET in Windows XP Home with Cassin...
Run ASP.NET in Windows XP Home with Cassini Sample Web Server
If you need to learn ASP.NET programming, then the first thing you need to install in your Windows XP Home PC is Cassini Sample Web Server. This article explains what you should have in place before you install the server, and explains how to download and configure it.
ASP.NET is owned by Microsoft and is an entirely new technology as compared with classic ASP. This technology allows you to write ASP.net server side commands hosted in an IIS-compatible server like Cassini Sample Web Server.
The very good thing about this sample web server is that it is FREE (open source). This is like XAMPP, when we are running local Apache-MySQL-PHP in a Windows-based operating system.
If you have a Windows XP Home computer, you would not be able to install IIS (Internet Information Services) properly since this is only available in Windows XP Professional OS.
It is not recommended that you make drastic tweaks to your Windows XP Home computer just to install and run IIS, because this can be a complicated procedure. Mistakes could ruin the existing Windows XP home configuration and make it unusable.
Instead, the safest way to run ASP.NET is to install Cassini Web Server. This tutorial is all about how to install, configure and prepare your Cassini Sample Web Server in your Windows XP Home computer to create dynamic websites written in ASP.NET. The information contained in this article is very basic and primarily intended for first time learners of ASP.Net programming.
In order to avoid incompatibility issues that cause installation problems, it is highly recommended that you have the following:
A valid installation of Windows XP Home Computer (Genuine).
Fully updated Windows components (your computer should have no pending Windows updates).
Microsoft .NET Framework 1.1
If you do not meet all of these requirements, it is hardly to possibly run Cassini Sample web server.
To see that Windows has the Microsoft .NET Framework 1.1 installed, go to: Control Panel -> Administrative Tools, and there you should see these two files:
Step 2: Double click the installer on your desktop after downloading. When you double click, there is an installation warning; click “Run.”
Step 3: The installation window is now launched. Just click “NEXT,” and then click “I accept the terms in the license agreement.” Click “NEXT” again.
Step 4: The installer will then ask you where to install the files. If you have an existing XAMPP installation or any local host installed in C:, you can install Cassini Web Server files in the next drive partition, such as E:. This will avoid any potential conflicting issues with running two local web servers at the same time. But use the default location, which is C:, if you have no other local host installation.
Step 5: After you have selected the drive, continue the installation until the installer automatically launches the ReadMe file. In this case the installation has been completed; you can close the Readme file.
Step 6: Go to Control Panel -> Administrative Tools and look for Microsoft .NET Framework 1.1 Configuration. Then go right to it and click OPEN.
Step 7: On the left side, you should see the following:
My Computer
Assembly Cache
Configured Assemblies
Remoting Services
Runtime Security Policy
Applications
Click on “Assembly Cache.”
Step 8: Click “Add an Assembly to the Assembly Cache.” See screen shot below:
Step 9: An “Add to Assembly” will open. Navigate to C:CassiniCassini.dll, if you have installed your Cassini Sample Web server in Drive C; otherwise, select the appropriate path. After the file has been located and selected, click “Open.”
Step 10: In your Windows XP, navigate to the folder where the Cassini Sample Web Server has been installed.
Step 11: Find CassiniWebServer.exe. You can locate it as an application type program. See screen shot below (the CassiniWebServer.exe is highlighted):
Proceed to the next section if all of the above procedures have been followed.
This is the last step before you can start running your local ASP.NET web server. Right click on the CassiniWebServer.exe and open. The first time you open it, Cassini Sample Web Server asks you for the following information:
Application Directory
Server Port Number
Virtual Root
By default, the server port number is set to “80” and the virtual root is set to “/”. Now this is the tricky part of the installation. The server port number should not conflict with other existing local web servers installed on your Windows XP Home computer.
For example, XAMPP by default uses port 80 for normal operations. If you are also a PHP developer and use XAMPP for testing, then port 80 is permanently assigned for XAMPP.
Since Cassini Personal Web server uses Port 80 by default, you should change it to another port number in such a way it won’t create port conflict with your existing web servers.
In this case you can use port 8080 for Cassini Web Server and port 80 for XAMPP. This is only true if you have XAMPP installed on your computer. Otherwise, if there are no other local web servers installed, use port 80 as the default. Or if you plan to install XAMPP in the future, port 8080 is the recommended port.
The next tricky thing to be configured is the “Application Directory.” This is a Windows file path specifying where you would like to store your HTML and ASP.NET files. It is recommended that you create a new folder in the same directory where the Cassini Sample web server resides.
So for example, suppose it is installed in E:. I will create a new directory called “ASPNET” where I would like to store my ASP.NET files and other HTML-related documents. Finally, suppose I will use port 8080, since port 80 is already being used by XAMPP. Below is the final configuration screen shot:
Finally the server can be started by clicking “Start.” After clicking on this, you can view the files under:
http://localhost:8080/
So for example, if I save index.htm in the ASPNET folder that I created, I can view that web page using a browser in:
http://localhost:8080/index.htm
Once the Cassini Web Server is started, it will continue to run unless you click “STOP.” See the screen shot below:
You can even run two local web servers at the same time using different technologies as long as they use different ports (port 80 for Apache, and port 8080 for Cassini Web server/ASP.NET).