includes errors
-
all worked fine till uploading it. NOW errors My include in my ASP is This picks up the included file fine and then this is the include file <% ' FileName="Connection_ado_conn_string.htm" ' Type="ADO" ' DesigntimeType="ADO" ' HTTP="false" ' Catalog="" ' Schema="" Dim MM_laptop_STRING MM_laptop_STRING = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=http://www.comptraders.co.za/Laptop.mdb;Persist Security Info=False" %> From there I get an error then that it cannot find my mdb.(OR invalid file)???? Even if I do the Source=Laptop.mdb Nothing works. Error 80004005 Invalid file ??? ALL my files is now in ONE directory (ROOT) Before I actually moved all to one dir I had error 0126 that it cannot find the file. ANY IDEAS PLEASE? I am getting a bit irritated with this now ? :) this is me
-
all worked fine till uploading it. NOW errors My include in my ASP is This picks up the included file fine and then this is the include file <% ' FileName="Connection_ado_conn_string.htm" ' Type="ADO" ' DesigntimeType="ADO" ' HTTP="false" ' Catalog="" ' Schema="" Dim MM_laptop_STRING MM_laptop_STRING = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=http://www.comptraders.co.za/Laptop.mdb;Persist Security Info=False" %> From there I get an error then that it cannot find my mdb.(OR invalid file)???? Even if I do the Source=Laptop.mdb Nothing works. Error 80004005 Invalid file ??? ALL my files is now in ONE directory (ROOT) Before I actually moved all to one dir I had error 0126 that it cannot find the file. ANY IDEAS PLEASE? I am getting a bit irritated with this now ? :) this is me
hi there, evlxtc wrote: _Data Source=http://www.comptraders.co.za/Laptop.mdb_ just guess: Data Source should be the physical path on server u hosted ur website << >>
-
hi there, evlxtc wrote: _Data Source=http://www.comptraders.co.za/Laptop.mdb_ just guess: Data Source should be the physical path on server u hosted ur website << >>
SERVER IN USA ME IN RSA I do not know the physical (C:\ what ever) path on that server, but surely that should not be needed. The http:// path I put in I can see the files there if I type it in by hand each one, but the one does not pick the other up??? What to do? this is me
-
SERVER IN USA ME IN RSA I do not know the physical (C:\ what ever) path on that server, but surely that should not be needed. The http:// path I put in I can see the files there if I type it in by hand each one, but the one does not pick the other up??? What to do? this is me
There are a couple problems with your setup. First, you can't connect ADO through HTTP, which is what you are doing by using the URL (http://....). Granted, you can see the file when you type in its url, but that just allows you to download the database via your browser. HTTP doesn't have anything to do with ADO, which is what you use to get the data out of the file and into your page. You will have to use the actual file system path. Here is how you can find the path to the folder your database is in. Make a file with the following code and place it in the same folder as your database and browse for it. <% longpath=Server.MapPath(".") Response.Write(longpath) %> This will show you the full path to this file. Subtitute the filename of the database with the file name of the script, and there is your path to the database. The second problem I see here is that you have published your database to a folder that is viewable to the entire world. This means that anyone could go to your site and download the entire database file. Perhaps your database does not have any sensitive data, but let's say for example that you had login names and passwords in it. Someone could download your database, open it, and have full access to your site. This is pretty poor security. If I were you, I'd call up my hosting company and ask about a database folder which is outside of the document root, thus placing the database somewhere that only you can access it. They will also tell you the path to this folder, which solves your first problem as well.
-
There are a couple problems with your setup. First, you can't connect ADO through HTTP, which is what you are doing by using the URL (http://....). Granted, you can see the file when you type in its url, but that just allows you to download the database via your browser. HTTP doesn't have anything to do with ADO, which is what you use to get the data out of the file and into your page. You will have to use the actual file system path. Here is how you can find the path to the folder your database is in. Make a file with the following code and place it in the same folder as your database and browse for it. <% longpath=Server.MapPath(".") Response.Write(longpath) %> This will show you the full path to this file. Subtitute the filename of the database with the file name of the script, and there is your path to the database. The second problem I see here is that you have published your database to a folder that is viewable to the entire world. This means that anyone could go to your site and download the entire database file. Perhaps your database does not have any sensitive data, but let's say for example that you had login names and passwords in it. Someone could download your database, open it, and have full access to your site. This is pretty poor security. If I were you, I'd call up my hosting company and ask about a database folder which is outside of the document root, thus placing the database somewhere that only you can access it. They will also tell you the path to this folder, which solves your first problem as well.
Thanks. I actually had my db in another folder and more secure but in utter frustration of it all not working moved it to the same folder just to get it working. I will try this asap amnd get it working FIRST and then worry about the location and security. The server was also just built (because of my request) so I am not sure that it is all set up correctly on there side, but I am sure it must be THANKS AGAIN FOR THE DETAILED ANSWER. this is me