Config file path

  • kmc1499

    kmc1499 - 2011-05-02

    IM having some issues with the config file as it relates to the web links. I have all the files in a folder called "blog" in the iis root folder. With the config file as is when you try to go to any of the links it says the browser dosent understand "d". I need to know what to but in the code below so my links work correctly. Any help would be greatly appreaciated

     if ($_SERVER['SCRIPT_FILENAME'] == realpath($_SERVER['SCRIPT_FILENAME'])) {
            define('BASEURL', preg_replace("/^" . str_replace("/", "\/", $_SERVER["DOCUMENT_ROOT"]) . "/", "", ROOT_DIR));
        } else {
            define('BASEURL', '/' . basename(dirname(dirname(__file__))) . '/');
  • nabber00

    nabber00 - 2011-05-04

    Can you tell me what your "DOCUMENT_ROOT' variable is set to?  You can see this on the "View PHP Configuration" page when you are logged in.

  • kmc1499

    kmc1499 - 2011-05-04

    My Doc root says its "C:\Inetpub\wwwroot" but for the site i made a virtual directory due to space issues so it actually sits on the d drive

  • nabber00

    nabber00 - 2011-05-05

    I think the solution is the same as for bug ID: 3164275:

    In this case, you need to
    set BASEURL correctly in scripts/config.php. Update this line:

    define('BASEURL', '/' . basename(dirname(dirname(__file__))) . '/');

  • kmc1499

    kmc1499 - 2011-05-06

    Wow i should have been able to find that on my own (the bug with the fix) but thanks for the help, it works perfectly now!


Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

No, thanks