Page 1 of 1

New Manchuria update

Posted: Thu 27 Dec 2007 3:39 am
by Kapt
Installed new Manchuria and have one error appears at top of front page and on Statistics page:

Notice: Undefined variable: DOCUMENT_ROOT in C:\Program Files\Abyss Web Server\htdocs\MP4\Scripts\MP-Misc.php on line 526

http://www.virtual23squadron.com/MP4/index.php
http://www.virtual23squadron.com/MP4/St ... istics.php

Posted: Thu 27 Dec 2007 7:18 pm
by IV/JG7_4Shades
Hi Kapt,

Thanks for checking it out so fast. That error looks to be something to do with the environment. I went a-Googling and found the following:

http://bugs.php.net/bug.php?id=11759&edit=1

Maybe this will help - defining DOCUMENT_ROOT in your Windows environment.

Cheers,
4Shades

Posted: Fri 28 Dec 2007 12:07 am
by Kapt
It wasn't a problem with the other version but i have no idea what the variable for DOCUMENT_ROOT should be set to.

Posted: Fri 28 Dec 2007 6:52 am
by IV/JG7_4Shades
Hi Kapt,

I have not changed any coding pertaining to the use of DOCUMENT_ROOT in years. The line number 526 in MP-Misc.php is where the MP tries to locate the DB from the given address. Maybe in this install you have changed the location of your DB?

Basically, DOCUMENT_ROOT is a filesystem path that points to where your webserver stores all its HTML files. For an Abyss web server, it might be something like "C:\Program Files\Abyss\htdocs". That can be as it may, the worrying thing is that your PHP does not initialize the $DOCUMENT_ROOT variable, which it should. Have you tried the usual PHP install test, using the simple PHP file:

<?php
phpinfo();
?>

Presumably when browsed through your server, that reports everything OK and $DOCUMENT_ROOT is initialized?

Cheers,
4Shades

Posted: Fri 28 Dec 2007 9:12 am
by Kapt
The DB is in the same location as is the root folder, just everything was updated to the newer version. I can reverse back to prev version and all looks fine. Using the phpinfo things look ok there. :roll:

Posted: Fri 28 Dec 2007 1:49 pm
by Kapt
Well with some help from a friend we got it figured out.

In the database setup to .mdb file path i was using forward slashes ' / ' as before but now i need to use back slashes ' \' to match windows.

Posted: Sat 29 Dec 2007 7:23 am
by IV/JG7_4Shades
Hmm, wow. Glad to hear it's working, anyway.

Cheers,
4Shades

Posted: Sat 29 Dec 2007 5:04 pm
by Kapt
To point out another problem: Some of the ships are using a default speed of 54000

Image

So far it was a Type VIII sub and a patrol boat.