X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=application%2FUtils.php;h=7556d3c9a9a46c7011fc68d659d7752531907790;hb=adc4aee80f7cd3242f65f0b316af2b560a64712c;hp=35d652241bb6a5a4c42c7ded7b7381be48dc7f15;hpb=b3051a6aae446e063c3b6fa4a6a600357a9f24af;p=github%2Fshaarli%2FShaarli.git diff --git a/application/Utils.php b/application/Utils.php index 35d65224..7556d3c9 100644 --- a/application/Utils.php +++ b/application/Utils.php @@ -270,3 +270,13 @@ function normalize_spaces($string) { return preg_replace('/\s{2,}/', ' ', trim($string)); } + +function getAllTheme($raintpl_tpl) +{ + $allTheme = glob($raintpl_tpl.'/*', GLOB_ONLYDIR); + foreach ($allTheme as $value) { + $themes[] = str_replace($raintpl_tpl.'/', '', $value); + } + + return $themes; +}