: : : Hi,
: : :
: : : I have a database in a password folder on a web site. How do I still get the pages to link to the database? Do i just add the username and password to the connection string?
: : :
: : : Thanks
: : :
: :
: : What kind of database ? What kind of script-language do you use and how do you want to connect ?
: : And what exactly do you mean by "I have a database in a password folder" ?
: :
: I'm using ASP and the site is on a win2k server running IIS 5.1
: The Access Database is in a folder called _private in the root of the website. This folder is passworded to stop casual entry. I want to connect to this database through a ASP connection script. But it says that I don't have permission to do this.
:
:
Can you connect to the database if it's in another directory ?
You probably can, so here's what I think the problem is.
Your protected directory should have some file telling it that it's protected and should ask for a password ( on Apache it's called .htaccess , I don't know what it's called on IIS )
Anyway, this file will say something like
"deny from all"
You should add something like "allow from <serverip>" and then webpages on your site should be able to access the database.
Check
http://www.javascriptkit.com/howto/htaccess.shtml for more info on .htaccess ( again, I don't know how IIS handles this, but probably in a simmilair way )