Knowledge Base Hub

Browse through our helpful how-to guides to get the fastest solutions to your technical issues.

Home  >  How-Tos  >  How to Mention Connection String in web.config File?
Top Scroll

How to Mention Connection String in web.config File?

 2 min

You can add/mention the connection string in the web.config file in five simple steps.

1. Log in to the Plesk panel.

2. Select the File option to open the File Manager.

3. Go to the httpdocs folder and open the web.config file.

 

4. The file will open in the Code Editor window. Add the below code in the configuration section.

<connectionStrings>
<add name="ConnectionString" connectionString="Data Source=SERVER IP;Initial Catalog=DBname;User Id=DBuser;Password=DBuser password;" providerName="System.Data.SqlClient" />
</connectionStrings>

5. Once you are done, click the Save button.

That’s it! With this, you will have successfully mentioned the connection string in the web.config file.

For our Knowledge Base visitors only
Get 10% OFF on Hosting
Special Offer!
30
MINS
59
SECS
Claim the discount before it’s too late. Use the coupon code:
STORYSAVER
Note: Copy the coupon code and apply it on checkout.