Answer the question
In order to leave comments, you need to log in
How to publish asp.net mvc application on server?
I use VS2013, launched a virtual machine with win server 2012, installed iss, mssql server 2012 express too.
The files were transferred via ftp.
When requesting a machine address, a site page appears with the message "There was an error processing the request.". I understand that it was not possible to connect to the database. Lost half a day, and did not find any normal manual for transferring the project to the server.
With all sorts of localDb, sqlexpress, connectionString, web Deploy, a complete mess in my head.
Through sql server express, I made a database from the mdf file that was, added the user, but did not understand what to write in the connectionString?
Experiments with web Deploy ran into the same thing, I could not connect to the database.
What is the best/quickest way to set up publishing?
Answer the question
In order to leave comments, you need to log in
There are a million tutorials on this topic, for example
www.asp.net/mvc/tutorials/deployment
I just didn’t understand, are you deploying a site on your own server?
What's the problem with the connection string? Maybe you are specifying the server address incorrectly? If the base is located on a hosting on the Internet, then you can see its address directly on this hosting.
If on the local machine, then the server name for SqlServer will be .\SQLEXPRESS
For example:
< add name="MyDatabase" connectionString="Data Source=.\SQLEXPRESS;Initial Catalog=MyDatabase;Integrated Security=SSPI" providerName="System.Data. SqlClient" />
For SqlServer CE providerName = "System.Data.SqlServerCe.4.0"
When publishing a site, you must also publish the database itself.
Well, yes, the SQL server must already be installed on the server where the site will live. or on another, but you need to connect to the SQL server from the machine where the site lives
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question