how to encrypt a connection string in web.config file?

Answer Posted / kinjal panchal

<configuration>
<appsetting>
<add key="debug" value="true"/>
<add key="server" value="your server name"/>
<add key="Database" value="your databse name"/>
<add key="username" value="your username"/>
<add key="password" value="your password"/>
</appsetting>

<connectionstring>
<add name="cnnectionstrigname"
connectionstring="datasource=server name; initial
catalog=database name; user id=your username; password=your
password" providername="system.data.sqlclient"/>
</connectionstring>
</configuration>

Is This Answer Correct ?    4 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the use of the tag in the web.config file?

738


What is redirecting behavior?

723


Is asp.net and .net are same or different?

708


What is difference between session and application in asp net?

734


Explain the main function of razor in asp.net? : asp.net mvc

809


How can u debug your .net application?

780


What is the difference between mvc and asp.net? : Asp.Net MVC

685


1.can we add connection string in global.asax?????????? 2.what are the default files included when we create new web application????

19685


Explain the use of duration attribute of @outputcache page directive.

861


How do we access view state value of this page in the next page?

828


what is publisher?

1848


What r the asp.net list controls and diff. Between them?

719


Explain the differences between clr & cts?

743


Mention few asp.net validators.

751


What is the good practice to implement validations in aspx page?

840