Jump to content

ROOT in login.php ( error or not error )


gAp

Recommended Posts

In a file login.php from last SVN
have code on line 20:

// Checking path
$pathServer = preg_replace('!^/!', '', $_SERVER['PHP_SELF']);
$pathUser = preg_replace('!^/!', '', str_replace($_SERVER['DOCUMENT_ROOT'], '', $_SERVER['SCRIPT_FILENAME']));
if (strcmp($pathServer, $pathUser))
...

In my surroundings DOCUMENT_ROOT = '/',
then the function str_replace will be replaced '/' to ' '.
As a result of an error:

Path is not the same between your browser and you server :
- Server:
shop/admin23/login.php
- Browser:
homewwwXXXX.XXshopadmin23login.php
==================================

Donc, si je pas raison?
D'erreur s'affiche encore.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...