mirror of https://github.com/aredn/aredn.git
bugfix: Untill user visit status page theme is not set.
Move default theme selection to html_header() to solve theme not being set.
This commit is contained in:
parent
d59709d840
commit
42ee986cd3
|
@ -61,6 +61,11 @@ sub html_header
|
|||
print "<meta http-equiv='expires' content='0'>\n";
|
||||
print "<meta http-equiv='cache-control' content='no-cache'>\n";
|
||||
print "<meta http-equiv='pragma' content='no-cache'>\n";
|
||||
|
||||
# set up the style sheet
|
||||
mkdir "/tmp/web" unless -d "/tmp/web"; # make sure /tmp/web exists
|
||||
symlink "/www/aredn.css","/tmp/web/style.css" unless -l "/tmp/web/style.css"; # default to aredn.css
|
||||
|
||||
# Prevent browser caching of the css file
|
||||
my $rnum=`date +%s`;
|
||||
chomp($rnum);
|
||||
|
|
|
@ -48,10 +48,6 @@ $config = "not set" if $config eq "" or not -d "/etc/config.$config";
|
|||
|
||||
read_postdata();
|
||||
|
||||
# set up the style sheet
|
||||
mkdir "/tmp/web" unless -d "/tmp/web"; # make sure /tmp/web exists
|
||||
symlink "/www/aredn.css","/tmp/web/style.css" unless -l "/tmp/web/style.css"; # default to aredn.css
|
||||
|
||||
if($parms{css} and -f "/www/$parms{css}" and $parms{css} =~ /\.css$/i) {
|
||||
unlink "/tmp/web/style.css";
|
||||
symlink "/www/$parms{css}","/tmp/web/style.css";
|
||||
|
|
Loading…
Reference in New Issue