February 6th, 2013, 10:03 PM
Writing a new data connection string nopCommerce
I've been really digging into Asp.Net MVC recently and have been customizing the open source NopCommerce store in Visual Studio 2012. I've successfully added a simple new page to my store and wanted to add some database interaction to store simple strings (for now), however, NopCommerce uses a settings.txt file instead of Web.Config for database connection.
My question is how do I write this:
To a Settings.Txt file and is that all I have to do to establish the connection?
<add name="Nop.Web.Models.ShowsDataContext" connectionString="Data Source=(LocalDb)\v11.0;Integrated Security=SSPI;AttachDBFilename=|DataDirectory|\Nop.Web.Models.ShowsDataContext.mdf" providerName="System.Data.SqlClient" />
I've asked on the NopCommerce threads but got nowhere.