Pay attention to the following points when deploying a project to a server:

Source: Internet
Author: User

Pay attention to the following points when deploying a project to a server:
1. The connection string is generally used for windows Authentication during local development, but SQL server authentication is used on the server. The following error may occur. User 'nt AUTHORITY \ NETWORK service' Login Failed and then look at the web. the connection string <add name = "Letters_ManagementEntities" connectionString = "metadata = res: // */Model. letter. csdl | res: // */Model. letter. ssdl | res: // */Model. letter. msl; provider = System. data. sqlClient; provider connection string = & quot; Data Source =. \ sqlexpress; Initial Catalog = Letters_Management; Integrated Security = True; MultipleActiveResultSets = True; App = EntityFramework & Quot; "providerName =" System. data. entityClient "/> note the blue annotation, which indicates windows authentication, so you need to change the SQL server Authentication, <add name = "Letters_ManagementEntities" connectionString = "metadata = res: // */Model. letter. csdl | res: // */Model. letter. ssdl | res: // */Model. letter. msl; provider = System. data. sqlClient; provider connection string = & quot; Data Source = db.cloud.istudy.sh.cn; Initial Catalog = Letters_Management; user id = sa; password = Password01 !; Persist security info = True; MultipleActiveResultSets = True; App = EntityFramework & quot; "providerName =" System. data. entityClient "/> 2.css references an image. If there is only one project on the server, it does not matter. If there is a similar case, you need to change the image connection # logo {background-image: url (".. /Images/logo.jpg "); width: 100%; height: 142px; fill in the global style sheet. connections referenced in js often have such connections in the view. <a href = "~ /Home/writeletter "> writing letters </a> In the connection "~ "This symbol is not available in js files, so you need to use another url:" @ Url. action ("delete", "home", new {id = Model. ID}) "The connections in js will be automatically converted.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.