I have created an ASP.NET web application using visual studio.
Here is the github repository
Currently, a webpage on my website looks like this I only make changes to index.html.
Now that I want to deploy this ASP.NET application on my website, I assumed I would just upload the files to the server, unfortunately, the result does not look like what visual studio displays.
Here is what the webpage currently looks like.
What changes do I need to make to my ASP.NET application so that it will be displayed properly on my website?
Basically before deployment you need to make sure following
Then you need to Publish the web application from visual studio. Publishing process will compile your application and will create a full package containing Dll, images, styles and aspx/html files + config files.
Before publishing starts, visual studio will ask you to create a public profile and there you need to specify Path and Build mode (debug or Release). Path can be of your local machine Or directly of live server (I prefre local though)
Once publish succeeds, you are ready to copy the entire publish folder to live (if your publish path was local).
For more information on deployment read following MSDN reference Deployment process
Which webserver you are using?
The http://devinhaslam.com
website is hosted from a apache webserver. If you want run a .net website on a apache you need asp.net core check this https://docs.microsoft.com/en-us/aspnet/core/publishing/apache-proxy
If you run the website on a IIS, you must only publish the bin folder. Check this documentation https://msdn.microsoft.com/en-us/library/dd465337(v=vs.110).aspx
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.