From: Michael Wallner Date: Fri, 20 Dec 2013 15:17:46 +0000 (+0100) Subject: open_basedir fix X-Git-Url: https://git.m6w6.name/?a=commitdiff_plain;h=1b07c8be71df7a20411592d3f154fc741b1a0502;p=mdref%2Fmdref open_basedir fix --- diff --git a/mdref/Path.php b/mdref/Path.php index efa208a..e0d00c7 100644 --- a/mdref/Path.php +++ b/mdref/Path.php @@ -70,7 +70,15 @@ class Path * @return string */ function getFullPath($ext = "") { - return $this->baseDir . DIRECTORY_SEPARATOR . $this->path . $ext; + $path = ""; + if (strlen($this->baseDir)) { + $path .= $this->baseDir . DIRECTORY_SEPARATOR; + } + if (strlen($this->path)) { + $path .= $this->path; + } + $path .= $ext; + return $path; } /** @@ -97,4 +105,4 @@ class Path } return $head . "
" . $html ."
"; } -} \ No newline at end of file +}