Small fixes

This commit is contained in:
RainLoop Team 2014-03-14 19:55:47 +04:00
parent 7d7c05737f
commit d1a7dd9491
5 changed files with 33 additions and 33 deletions

View file

@ -599,9 +599,7 @@ class Http
*/
public function GetPath()
{
$sUrl = \trim(\substr($this->GetServer('REQUEST_URI', ''), 0,
\strrpos($this->GetServer('REQUEST_URI', ''), \basename($this->GetServer('SCRIPT_NAME', '')))), '/');
$sUrl = \ltrim(\substr($this->GetServer('SCRIPT_NAME', ''), 0, \strrpos($this->GetServer('SCRIPT_NAME', ''), '/')), '/');
return '' === $sUrl ? '/' : '/'.$sUrl.'/';
}