pa_broon74 wrote:
Quote:
Hey folks.
>
Not sure if this is the right place to be asking this, (I looked for a
PHP group for dopes but couldn't find one...)
That is OK, dopes are welcome here. ;-)
You're probably going to
Quote:
think I'm a philistine for doing this but what can I do...
>
I downloaded a copy of DBqwiksite and have "designed" a wee PHP
website based on an access database with only one table with 7
datafields. Its laughably straight forward. The thing is, I have no
idea what the file structure on my web space should be like.
>
Do I put the database in the root folder or does it go in a seperate
database folder? I have to say, don't believe the blurb on
DBqwiksite's box, its so easy to get something up and running on your
PC but as soon as you try to publish; it falls flat on its face.
>
Where to put the yourDB.mdb file?
Best thing to do is make that general, so you don't have to decide upfront,
since you don't know the target machine.
How to make it flexible?
Define the location of the database in a file.
Include this file in all pages that use the database.
You can also add the connectstring in the same file.
That way you can easily change location without having to check all your
scripts.
Have a look at
www.php.net and find the function:
require() or probably better: require_once()
You can also use include() but require will throw an error at you when the
file cannot be found, which makes more sense on a page that demands
databaseaccess. :-)
Quote:
It has a 'deploy' wizard but so far, it has been distinctly unwizard-
like in that it deploys everything other than the database itself.
Well, no help there. I never used that program.
Quote:
>
Any basic pointers would be appreciated and do assume that I know very
little about PHP. If I see INVALID QUERY once more on my screen its
going out the window... :-)
Don't hit any Linux users please. ;-)
Regards,
Erwin Moller