mirror of
https://git.sekbaer.de/Friendica/friendica.git
synced 2025-06-17 04:15:15 +02:00
Merge https://github.com/friendica/friendica into pull
This commit is contained in:
commit
ac18d7289b
19 changed files with 2112 additions and 1383 deletions
15
boot.php
15
boot.php
|
@ -520,6 +520,19 @@ if(! class_exists('App')) {
|
|||
$this->is_tablet = $mobile_detect->isTablet();
|
||||
}
|
||||
|
||||
function get_basepath() {
|
||||
|
||||
$basepath = get_config("system", "basepath");
|
||||
|
||||
if ($basepath == "")
|
||||
$basepath = $_SERVER["DOCUMENT_ROOT"];
|
||||
|
||||
if ($basepath == "")
|
||||
$basepath = $_SERVER["PWD"];
|
||||
|
||||
return($basepath);
|
||||
}
|
||||
|
||||
function get_baseurl($ssl = false) {
|
||||
|
||||
$scheme = $this->scheme;
|
||||
|
@ -1895,7 +1908,7 @@ function clear_cache($basepath = "", $path = "") {
|
|||
$fullpath = $path."/".$file;
|
||||
if ((filetype($fullpath) == "dir") and ($file != ".") and ($file != ".."))
|
||||
clear_cache($basepath, $fullpath);
|
||||
if ((filetype($fullpath) == "file") and filectime($fullpath) < (time() - $cachetime))
|
||||
if ((filetype($fullpath) == "file") and (filectime($fullpath) < (time() - $cachetime)))
|
||||
unlink($fullpath);
|
||||
}
|
||||
closedir($dh);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue