Thursday, September 09, 2010
  Search
 
Register
Login
 
How to Install and Configure ActiveDirectory Provider for DotNetNuke 5.0
 The directions for installing and configuring extensions in DotNetNuke 5.0 are very similiar, but slightly different than from previous versions. Here's how to install the ActiveDirectory authentica...

Find this article and more in the category

Read This Article . . .

More Ways to Install DotNetNuke Modules with the URL Method
While DotNetNuke has a built in mechanism for installing modules, there is another method you can use as well. This is a great alternative to use especially when you are trying to install larger mod...

Find this article and more in the category

Read This Article . . .

Installation from the DotNetNuke Install Package 4.90 to Windows XP Professional
OK, so you made the leap and downloaded an installation package of DotNetNuke 4.x.   But now what do I do?  Well, here's a step-by-step instruction guide to get you up and running with DotNetNuke 4....

Find this article and more in the Localhost category

Read This Article . . .

Getting Started with Code Endeavors Ajax Compiled Module Template
DotNetNuke Ajax development just got easy thanks to Jon Henning and his Ajax Compiled Module templates. He’s got them listed on CodePlex, they’re updated for DNN 5, and they are available in C# and V...

Find this article and more in the category

Read This Article . . .

Setting Up the DotNetNuke Side of Multi-Websites
Ok, so by now you know that DotNetNuke can handle multiple websites, but you still want to know why. Well, it’s pretty easy once you know how to do it, but it can be pretty confusing to some who are ...

Find this article and more in the category

Read This Article . . .

New DotNetNuke 5.0 Cambrian Package Writer for Module Developers
Attention developers! DotNetNuke 5.0 Cambrian has a nifty new tool to help developers package their modules nicely to fit with the new “Extensions” manager. Under the old Module Definitions manager, ...

Find this article and more in the category

Read This Article . . .

DotNetNuke 5 Cambrian Extropy Skin Features and Limitations
The new DotNetNuke Extropy skin looks very cool from a distance...leaps and bounds above the old default blue skin. But, it's got some limitations you should know about upfront.

Find this article and more in the category

Read This Article . . .

Quick Look at Some New Features of DotNetNuke 5 Cambrian
DotNetNuke’s much anticipated Cambrian has finally been made available as a Release Candidate and while it looks like the same ol’ packages from afar, it’s packed with some nice new features that are...

Find this article and more in the category

Read This Article . . .

Simple Intro to the DNN UserInfo Class
 New DNN developers often wonder how to expose information about logged in users to a custom DotNetNuke module. So, I threw together a very simple example to show how easy it is to begin using the bu...

Find this article and more in the DotNetNuke category

Read This Article . . .

Quick Check for Troubleshooting the CodeEndeavor Ajax Templates
I haven’t just installed the the template and created a module out of the box yet. However, I have come across a few things that I know to check and fix and I’m up and running in no time at all. If y...

Find this article and more in the category

Read This Article . . .

Recently Added Articles

Minimize
Article List

 

SERIES: Anatomy of a DNN Web.Config File-connectionStrings

12/9/2008 3:30:22 PM - By Briana Tarrance

Category: | | Comments 0

 

 

Related Links

The <connectionStrings> section holds all the necessary information for database communication from your website. At minimum, there will be at least one connection string for any DotNetNuke website.

By default, the config files that come with your DotNetNuke website has two connection string elements in them; although one is commented out (shown in green below). It is there mainly to give you the proper syntax for creating a connection to a database that is physically located outside of your websites structure. The uncommented connection string is the proper syntax for a connection made to a SQL Express database that is physically located in the App_Data folder within your website structure.

<connectionStrings>
   <!-- Connection String for SQL Server 2005 Express -->
   <add name="SiteSqlServer" 
        connectionString="Data Source=.\SQLExpress;
           Integrated Security=True;
           User Instance=True;
           AttachDBFilename=|DataDirectory|Database.mdf;" 
        providerName="System.Data.SqlClient" />
   <!-- Connection String for SQL Server 2000/2005
   <add name="SiteSqlServer" 
       connectionString="Server=(local);
           Database=DotNetNuke;
           uid=;pwd=;" 
       providerName="System.Data.SqlClient" /> 
   -->
 </connectionStrings>

As you can see from above, the “name” of the element is “SiteSqlServer”. While you technically can change this name, it is tightly coupled with DotNetNuke and changing the name may have adverse affects with DotNetNuke operations or third party modules. This connection string will dictate where your DotNetNuke data will be stored and retrieved from. Once you have your proper connection string set, there is no need to keep both of these strings on your config file. Some people choose to get rid of the extra lines for simplification and others prefer to leave it for future reference or “just in case”. Either way will work fine.

For more information on connection strings or for proper syntax with other types of database servers, visit http://www.connectionstrings.com/

powered by metaPost
 

Related Articles
Everything You Never Wanted to Know About the Config File

 
 
Copyright 2008 by Virtual-Essentials.com Privacy Statement    Terms Of Use