Merge pull request #7162 from nupplaphil/task/mod_view

Move mod/view to src/Module/Theme
This commit is contained in:
Hypolite Petovan 2019-05-18 21:07:27 -04:00 committed by GitHub
commit d3a4ed0111
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 33 additions and 27 deletions

View file

@ -1,27 +0,0 @@
<?php
use Friendica\App;
use Friendica\Util\Strings;
/**
* load view/theme/$current_theme/style.php with friendica context
*
* @param App $a
*/
function view_init(App $a)
{
header("Content-Type: text/css");
if ($a->argc == 4) {
$theme = $a->argv[2];
$theme = Strings::sanitizeFilePathItem($theme);
// set the path for later use in the theme styles
$THEMEPATH = "view/theme/$theme";
if (file_exists("view/theme/$theme/style.php")) {
require_once("view/theme/$theme/style.php");
}
}
exit();
}