|
-
Jul 15th, 2007, 08:33 AM
#1
Thread Starter
Addicted Member
[2005] How do I move my ASPNETDB.MDF to my website?
I have created a login page and applied some rules and every thing is working perfectly on my machine , now how can I move everything to my website ? do I upload my ASPNETDB.MDF to my website ? If so , how do I link my login pages to connect to the database ?
-
Jul 15th, 2007, 08:49 AM
#2
Re: [2005] How do I move my ASPNETDB.MDF to my website?
There is a folder called app_data created by VS when automatically or you can add it as manually. put your mdf file there and change your DB connection string to attach DB from file
"I'm not normally a praying man, but if you're up there, save me... Superman!" - Homer Simpson
My Blog
-
Jul 15th, 2007, 12:13 PM
#3
Re: [2005] How do I move my ASPNETDB.MDF to my website?
And make sure your connection string is correct, and that it reflects what the new structure might be on the remote box.
-
Jul 15th, 2007, 12:47 PM
#4
Thread Starter
Addicted Member
Re: [2005] How do I move my ASPNETDB.MDF to my website?
Where do I place a connection string ? and what is the correct format ?
-
Jul 15th, 2007, 02:41 PM
#5
Re: [2005] How do I move my ASPNETDB.MDF to my website?
You can place it where ever you want. the "web.config" is a good idea (but make sure you encrypt it if it has the login info (password).
And there is no 1 connection string format, you can check this website for methods to build your connection string
"I'm not normally a praying man, but if you're up there, save me... Superman!" - Homer Simpson
My Blog
-
Jul 15th, 2007, 02:56 PM
#6
New Member
Re: [2005] How do I move my ASPNETDB.MDF to my website?
Don't the web.config already do this automatically for you when you created the database anyways? The connection string should be in place in there already, and it is just a matter of re-configuring it to your remote server.
-
Jul 15th, 2007, 03:46 PM
#7
Re: [2005] How do I move my ASPNETDB.MDF to my website?
 Originally Posted by the_menace
Don't the web.config already do this automatically for you when you created the database anyways? The connection string should be in place in there already, and it is just a matter of re-configuring it to your remote server.
Only when using wizards
"I'm not normally a praying man, but if you're up there, save me... Superman!" - Homer Simpson
My Blog
-
Jul 16th, 2007, 06:57 AM
#8
Thread Starter
Addicted Member
Re: [2005] How do I move my ASPNETDB.MDF to my website?
Sorry but I didn't get it ,
I already have a folder called App_Data , I uploaded this folder to my website , then what ?
I looked in to the web.config file and all I can see is this:
Code:
<?xml version="1.0" encoding="utf-8"?>
<configuration xmlns="http://schemas.microsoft.com/.NetConfiguration/v2.0">
<system.web>
<authorization>
<allow roles="Administrator" />
<deny users="?" />
</authorization>
</system.web>
</configuration>
do I need to add the connection string in between these lines and am all set ?
Oh and my webhosting company supports using (MS SQL Database) , is that the same as (Microsoft SQL Server 2005) ?
Last edited by bomayed; Jul 16th, 2007 at 07:25 AM.
-
Jul 16th, 2007, 12:55 PM
#9
Re: [2005] How do I move my ASPNETDB.MDF to my website?
1- well, you have to ask.. MS SQL might mean SQL 2000 or SQL 2005 (which supports both)
2- The app_data must contain your DB .mdf file to work.
3- You need to change the connection string where ever you put it. and in your case it's not in the web.config. (even though putting it in the web.config would be a better idea)
"I'm not normally a praying man, but if you're up there, save me... Superman!" - Homer Simpson
My Blog
-
Jul 18th, 2007, 02:29 PM
#10
Re: [2005] How do I move my ASPNETDB.MDF to my website?
You really should contact your host and ask them these details. They might have a different folder just for MDFs and you'll need to change your connection string to reflect that.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|