Monday, October 14, 2013

How To : Install ASP.net

Now that we have IIS installed, we need to add functionality of being able to create web applications. Lets use ASP.NET.

What is ASP.NET? ASP.NET is a Microsoft development framework for building web pages and web sites with HTML, CSS, JavaScript and server scripting. The server scripting can be coded in VB or C#.

Since ASP.NET is combined with IIS servers, we again do not need to install anything to run it. All we need to do to install it is :

To start the installation, open your start menu and type "Programs and Features" in the search bar.

Click the Programs and Features item.

Once in the Programs and Features page, click Turn Windows features on or off located on the left hand side of the window.



After clicking the item, a new popup will appear.




  1. Expand the Internet Information Services section
  2. Expand the World Wide Web Services section
  3. Expand the Application Development Features section
  4. Make sure everything is checked inside this section
  5. Click OK and wait for the install to finish

Once it is done we have successfully installed ASP.NET, however we need to configure it first.

Open the start menu, and type IIS in the search bar.

Click the Internet Information Services Manager and let it open. When it opens you should see the following :



Click Change .NET Framework Version and a popup will appear and in the drop down you should see  v4.0xxxxx . Make sure that one is selected and click OK.

Now on the left hand side, click Application Pools and select the ApplicationPool/Website you want to use version 4.0. A popup will appear, switch the version in each one you want to use ASP.NET 4.0 as well.

Now we need to change it one more place to make it the default version for every web application.



On the upper right hand side, you will see a link that says Set Application Pool Defaults. Lets click that and the very first item is the .NET Framework Version. Lets change that to 4.0 as well.



Now that everything is switched over, lets make an ASP.NET page.

Create a new file on your desktop and name it Default.aspx.

Insert the following code into the file

<HTML>
  <BODY>
  This page was last refreshed on <%= Now() %>.
  </BODY>
</HTML>
 
Save the file and drag it into one of your websites.

Lets go check it out !

Open a browser and type the website URL you chose to put it in and add a /Default.aspx to the end of it. If everything works out you should see a page that looks like :



Of course the date will be different (depending on when you ran it ;) ) But there should be a date appear.


Congratulations, you have completed all the tutorials on installing and configuring servers and modules.

Thanks for reading!


No comments:

Post a Comment