From fb8c2a5e46d12af1f228414dfc5a9ef6085386df Mon Sep 17 00:00:00 2001 From: mark_story Date: Thu, 7 Feb 2013 20:41:04 -0500 Subject: [PATCH] Make paths platform dependent. This fixes issues with the built-in PHP webserver on windows. Fixes #3608 --- lib/Cake/Network/CakeRequest.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/Cake/Network/CakeRequest.php b/lib/Cake/Network/CakeRequest.php index 59b2ee2a9..e5574c0e0 100644 --- a/lib/Cake/Network/CakeRequest.php +++ b/lib/Cake/Network/CakeRequest.php @@ -305,7 +305,7 @@ class CakeRequest implements ArrayAccess { $this->webroot = $base . '/'; $docRoot = env('DOCUMENT_ROOT'); - $docRootContainsWebroot = strpos($docRoot, $dir . '/' . $webroot); + $docRootContainsWebroot = strpos($docRoot, $dir . DS . $webroot); if (!empty($base) || !$docRootContainsWebroot) { if (strpos($this->webroot, '/' . $dir . '/') === false) {