Add theme_path() for easy theming

This commit is contained in:
danpros 2023-12-10 10:29:15 +07:00
commit c02241509b

View file

@ -34,6 +34,16 @@ function site_path()
return $_path;
}
function theme_path()
{
if (config('views.root') == null)
error(500, '[views.root] is not set');
return site_url() . rtrim(config('views.root'), '/') . '/';
}
function error($code, $message)
{
@header("HTTP/1.0 {$code} {$message}", true, $code);