Options to add a custom CSS file (#2076)

This commit is contained in:
Clément OUDOT 2020-01-28 15:14:24 +01:00
parent d2105a3730
commit faa65c4abf
2 changed files with 5 additions and 0 deletions

View File

@ -757,6 +757,7 @@ sub cookie {
$h{max_age} //= $self->conf->{cookieExpiration}
if ( $self->conf->{cookieExpiration} );
$h{SameSite} ||= $self->conf->{sameSite};
foreach (qw(domain path expires max_age HttpOnly SameSite)) {
my $f = $_;
$f =~ s/_/-/g;
@ -981,6 +982,7 @@ sub tplParams {
PORTAL_URL => $self->conf->{portal},
SKIN_PATH => $portalPath . "skins",
SKIN_BG => $self->conf->{portalSkinBackground},
CUSTOM_CSS => $self->conf->{portalCustomCss},
( $self->customParameters ? ( %{ $self->customParameters } ) : () ),
%templateParams
);

View File

@ -27,6 +27,9 @@
<link rel="stylesheet" type="text/css" href="<TMPL_VAR NAME="STATIC_PREFIX"><TMPL_VAR NAME="SKIN">/css/styles.css" />
<!-- //endif -->
<link rel="stylesheet" type="text/css" href="/portal.css" />
<TMPL_IF NAME="CUSTOM_CSS">
<link rel="stylesheet" type="text/css" href="<TMPL_VAR NAME="STATIC_PREFIX"><TMPL_VAR NAME="CUSTOM_CSS">" />
</TMPL_IF>
<!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries -->
<!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
<!--[if lt IE 9]>