|
@@ -59,9 +59,17 @@ if (isset(G::$LoggedUser['Notify'])) {
|
59
|
59
|
<link rel="stylesheet" href="<?=STATIC_SERVER?>styles/tooltipster/style.css?v=<?=filemtime(SERVER_ROOT.STATIC_SERVER.'styles/tooltipster/style.css')?>" type="text/css" media="screen" />
|
60
|
60
|
<?
|
61
|
61
|
if (empty(G::$LoggedUser['StyleURL'])) {
|
62
|
|
-?>
|
63
|
|
-<link rel="stylesheet" type="text/css" title="<?=G::$LoggedUser['StyleName']?>" media="screen"
|
64
|
|
- href="<?=STATIC_SERVER?>styles/<?=G::$LoggedUser['StyleName']?>/style.css?v=<?=filemtime(SERVER_ROOT.STATIC_SERVER.'styles/'.G::$LoggedUser['StyleName'].'/style.css')?>" />
|
|
62
|
+ if (($StyleColors = G::$Cache->get_value('stylesheet_colors')) === false) {
|
|
63
|
+ G::$DB->query('SELECT LOWER(REPLACE(Name, " ", "_")) AS Name, Color FROM stylesheets WHERE COLOR IS NOT NULL');
|
|
64
|
+ while (list($StyleName, $StyleColor) = G::$DB->next_record()) {
|
|
65
|
+ $StyleColors[$StyleName] = $StyleColor;
|
|
66
|
+ }
|
|
67
|
+ G::$Cache->cache_value('stylesheet_colors', $StyleColors, 0);
|
|
68
|
+ }
|
|
69
|
+ if (isset($StyleColors[G::$LoggedUser['StyleName']])) { ?>
|
|
70
|
+<meta name="theme-color" content="<?=$StyleColors[G::$LoggedUser['StyleName']]?>">
|
|
71
|
+<? } ?>
|
|
72
|
+<link rel="stylesheet" type="text/css" title="<?=G::$LoggedUser['StyleName']?>" media="screen" href="<?=STATIC_SERVER?>styles/<?=G::$LoggedUser['StyleName']?>/style.css?v=<?=filemtime(SERVER_ROOT.STATIC_SERVER.'styles/'.G::$LoggedUser['StyleName'].'/style.css')?>" />
|
65
|
73
|
<?
|
66
|
74
|
} else {
|
67
|
75
|
$StyleURLInfo = parse_url(G::$LoggedUser['StyleURL']);
|