Display blank page or no theme –aSP.NET MVC


I deployed my first ASP.NET MVC application to the Windows Server 2008 with IIS7.0. The package deployment was a great choice it deployed everything without any pain. But after I deployed when I try to access the URL it gave me  a blank page. I could not find out the issue. Then I came across this site to solve the issue.

http://stackoverflow.com/questions/557730/i-am-getting-blank-page-while-deploying-mvc-application-on-iis

Basically MVC pattern will try to hide all the error messages which is raised from the application for security reason. It’s a good idea but when it comes to the deployment we really don’t know what went wrong.

Later I enabled the HTTP ERROR and HTTP Redirection under Add Role Services in the Server Manager. Once I enable that I got to see the original error. In my case the application could not connect to SQL server. I fixed the issue.

image

 

After I fixed that error I could able to browse my site. But another problem came up. The site was naked without any css and images. I thought it’s a server browser which blocks the css. Later I tried in my machine it was still the same without css and images.

Later I found that Static Content was not enabled in the IIS Role. I enabled, it started to work…

image

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s