banner



How To Add Website In Iis Windows Server 2012

What is IIS?

IIS or Internet Data Server is the server used to host .Net web applications. IIS hosting is normally installed on a Window Server.

For users to access a website, it is required that the website is hosted on some sort of web server. There are different web servers available for different technologies. In .Cyberspace, the web server available is called Internet Information Services or IIS.

Once the spider web application is adult, it is then deployed on an IIS Server. This web application can so be accessed by the end users. There are two means to deploy an application to the server, you lot volition see both over here.

  • Using the File Copy method.
  • Using the Web publish method.

In this IIS tutorial, y'all will acquire-

  • How to Download and Install IIS
  • How to Deploy Website in IIS via File copy
  • How to Publish ASP.NET Website

How to Download and Install IIS

The below diagram shows the process menstruum for an IIS Server.

IIS Server Process Flow

IIS Server Procedure Menstruation

  1. The get-go role is the request sent by the user. The request will unremarkably exist a web page. An example could exist http://example.com/Default.aspx .
  • Here 'example.com' is a website hosted on the IIS Server.
  • 'Default.aspx' is a spider web page on the example.com website.
  • And then the user volition enter the URL http://example.com/Default.aspx in the web browser. The request will then get to the IIS Server, which has the example.com application.
  1. Once the request comes to the IIS server, it is candy. The IIS Server volition perform all the required operations as per request.
  2. Finally, the IIS Server sends the output back to the user. The output volition generally be HTML content sent back to the user. This HTML content volition be displayed in the web browser.

Let's look how we can install IIS on a Window Server.

  • Kickoff, download Windows server from the URL – https://msdn.microsoft.com/en-us/windowsserver2012r2.aspx and try it for 120 days.

How to Download IIS

  • Once installed, the following steps demand to be carried out for installing IIS.

Footstep 1) Go to Windows Server and Add roles

On Windows Server 2012, the default dashboard is shown as below.

  • The kickoff step is to click on the 'Add together roles and features' on the dashboard.
  • This allows one to install additional features on a server.

How to Install IIS on Windows Server

Step ii) Keep to next step

On the next screen, you lot need to click the Next button to proceed.

How to Install IIS on Windows Server

Step 3) Choose the installation method

In the side by side step, we need to perform two substeps

  1. The showtime is to choose the Part-based or feature installation. This will permit u.s.a. to perform the IIS Installation.
  2. Click the 'Next' button to go on.

Steps to Install IIS on Windows Server

Stride four) Select the server

In the next screen, you will see the proper name of the server on which the installation is taking identify. Click the Next button to proceed.

Steps to Install IIS on Windows Server

Step five) Cull the web server option

In the adjacent pace, we demand to perform two substeps

  1. Choose the Spider web server option. This will ensure that IIS gets installed.
  2. Click the 'Next' button to proceed.

Installing IIS on Windows Server

Stride 6) Proceed further

In the subsequent screen, click the next push button to proceed.

Installing IIS on Windows Server

Step 7) Commencement the installation

In the final screen, click the Install button to begin the installation.

How to Install IIS on Windows Server

In one case IIS has been installed, you tin can launch it, past going to search in Windows 2012.

  1. Enter the string 'inetmgr' which is the command for IIS.
  2. Then Internet Information Services Manager will come up. Click on this.

How to Install IIS on Windows Server

After you click on the above link, IIS will open, and you volition be presented with the below screen.

Process to Install IIS on Windows Server

In IIS, yous will have an initial site set up called Default Web Site.

If yous open up your browser and go to the URL http://localhost. You volition see the below output. This URL mainly goes to the Default Web site shown in the previous screen. This is the default page which indicates that the IIS Server is upward and running.

Process to Install IIS on Windows Server

How to Deploy Website in IIS via File re-create

After developing a spider web application, the next of import step is to deploy the web application. The web application needs to be deployed and so that it can exist accessed by other users. The deployment is washed to an IIS Web server.

There are various means to deploy a spider web awarding. Let'due south await at the commencement method on how to deploy spider web application on server, which is the File re-create.

Nosotros utilise the web application created in the earlier sections. Let's follow the beneath-mentioned steps on how to host awarding in IIS.

Step 1) Let's first ensure we have our web application 'DemoApplication' open in Visual Studio.

How to Deploy Website in IIS via File copy

Stride two) Open the 'Demo.aspx' file and enter the cord "Guru 99 ASP.Internet."

How to Deploy Website in IIS via File copy

<!DOCTYPE html> <html xmlns="http://www.w3.ore/1999/xhtml"> <head runat="server"> 	<title></title> </head>	 	<body> 	  <form id="form1" runat="server">          <div>           Guru 99 ASP.Internet          </div> 	  </form> 	</body> </html>

Now just run the application in Visual Studio to make sure it works.

Output:-

Steps to Deploy Website in IIS via File copy

The text 'Guru 99 ASP.Net' is displayed. You should get the above output in the browser.

Pace three) Now it's time to publish the solution.

  1. Right-click the 'DemoApplication' in the Solution Explorer
  2. Choose the 'Publish' Selection from the context menu.

Steps to Deploy Website in IIS via File copy

It will open some other screen (encounter step below).

Pace four) In the adjacent step, cull the 'New Contour' to create a new Publish profile. The publish profile will have the settings for publishing the web application via File re-create.

Process to Deploy Website in IIS via File copy

Step five) In the next screen we accept to provide the details of the profile.

  1. Requite a proper noun for the profile such equally FileCopy
  2. Click the OK button to create the profile

Process to Deploy Website in IIS via File copy

Step 6) In this pace, nosotros specifically mention that we are going to Publish website via File copy.

  1. Choose the Publish method equally File System.
  2. Enter the target location as C:\inetpub\wwwroot – This is the standard file location for the Default Web site in IIS.
  3. Click 'Next' button to keep.

Deploying Website in IIS via File copy

Footstep seven) In the next screen, click the Next push to proceed.

Deploying Website in IIS via File copy

Step viii) Click the 'Publish' button in the terminal screen

Deploy Website in IIS via File copy

When all of the above steps are executed, you will get the following output in Visual Studio

Output:-

Deploy Website in IIS via File copy

From the output, you lot will see that the Publish succeeded.

Now just open up the browser and go to the URL – http://localhost/Demo.aspx

Deploy Website in IIS via File copy

Yous can run across from the output that at present when you browse to http://localhost/Demo.aspx , the folio appears. It also displays the text 'Guru 99 ASP.Net'.

How to Publish ASP.NET Website

Another method to deploy the web application is via publishing a website. The central difference in this method on how to host web application in IIS is that

  • Y'all have more control over the deployment.
  • You can specify to which Web site you want to deploy your application to.
  • For case, suppose if you lot had two websites WebSiteA and WebSiteB. If you employ the Web publish method, you can publish your application to any website. Also, y'all don't need to know the physical path of the Web site.
  • In the FileCopy method, you accept to know the concrete path of the website.

Permit'south use the aforementioned Demo Application and see how to deploy ASP.Net awarding in IIS pace by step using the "website publish method."

Step 1) In this step,

  1. Correct-click the 'DemoApplication' in the Solution Explorer
  2. Choose the Publish Option from the context card.

How to Publish ASP.NET Website

Footstep two) On the next screen, select the 'New Profile' option to create a new Publish profile. The publish profile volition take the settings for publishing the web application via Web Deploy.

How to Publish ASP.NET Website

Step 3) In the next screen we have to provide the details of the contour.

  1. Requite a proper noun for the profile such as 'WebPublish'
  2. Click the 'OK' button to create the profile

Process to Publish ASP.NET Website

Step 4) In the next screen, you need to requite all the details for the publish process

  1. Cull the Publish method as Web Deploy
  2. Select the server as Localhost
  3. Enter the site name as Default Website – Remember that this is the name of the IIS website
  4. Enter the destination URL as http://localhost
  5. Finally, click the Next button to proceed

Process to Publish ASP.NET Website

Step v) Click the 'Adjacent' button on the following screen to continue

Steps to Publish ASP.NET Website

Step 6) Finally, click the Publish push button to publish the Website

Steps to Publish ASP.NET Website

When all of the to a higher place IIS hosting steps are executed, you will get the following output in Visual Studio.

Output:-

Publish ASP.NET Website

From the output, you will see that the Publish succeeded.

At present just open the browser and become to the URL – http://localhost/Demo.aspx

Publish ASP.NET Website

Yous tin can meet from the output that now when you browse to http://localhost/Demo.aspx , the folio appears. Information technology besides displays the text Guru 99 ASP.Net.

Summary

  • Later on an ASP.Net application is developed, the next step is that it needs to be deployed.
  • In .Cyberspace, free IIS hosting is the default web server for ASP.Net cadre hosting applications.
  • ASP.Cyberspace spider web applications can be deployed using File copy method.
  • ASP.Internet web applications can as well be deployed using Web Publish method.

Source: https://www.guru99.com/deploying-website-iis.html

Posted by: hidalgophers1974.blogspot.com

0 Response to "How To Add Website In Iis Windows Server 2012"

Post a Comment

Iklan Atas Artikel

Iklan Tengah Artikel 1

Iklan Tengah Artikel 2

Iklan Bawah Artikel