Upgrade to Kirby 3
This commit is contained in:
parent
80004a968c
commit
03ab30b8c1
64 changed files with 524 additions and 683 deletions
|
@ -1,6 +1,7 @@
|
|||
<?php
|
||||
if(!function_exists('panel')) {
|
||||
header("Content-Security-Policy: default-src 'self'; style-src 'self' 'nonce-nRfqpuKWNuYyUAFPTr6WVNZk9' 'unsafe-inline' https://fonts.googleapis.com; font-src 'self' https://fonts.gstatic.com; frame-src https://www.youtube-nocookie.com; script-src 'self' 'unsafe-eval' 'nonce-nRfqpuKWNuYyUAFPTr6WVNZk9' 'unsafe-inline' https://jannikb.aquila.uberspace.de/piwik/; img-src 'self' data: https://jannikb.aquila.uberspace.de/piwik/");
|
||||
## script-src unsafe-inline is needed for kirby panel
|
||||
header("Content-Security-Policy: default-src 'self'; style-src 'self' 'nonce-nRfqpuKWNuYyUAFPTr6WVNZk9'; script-src 'self' 'unsafe-inline'; img-src 'self' data:");
|
||||
}
|
||||
//header("X-Content-Type-Options: nosniff"); // enabled at server-side
|
||||
//header("X-Frame-Options: deny"); // enabled at server-side
|
||||
|
@ -8,11 +9,6 @@ if(!function_exists('panel')) {
|
|||
header("Strict-Transport-Security: max-age=31536000");
|
||||
header("Referrer-Policy: no-referrer");
|
||||
|
||||
/*
|
||||
License Setup
|
||||
*/
|
||||
c::set('license', 'K2-PRO-153c9c6accc73d9547e255a0daba8911');
|
||||
|
||||
/*
|
||||
Kirby Configuration
|
||||
*/
|
||||
|
@ -24,16 +20,12 @@ c::set('smartypants.attr', 2); // -- for en-dash, --- for em-dash
|
|||
c::set('smartypants.doublequote.open', '„');
|
||||
c::set('smartypants.doublequote.close', '“');
|
||||
|
||||
c::set('ssl', true);
|
||||
|
||||
/*
|
||||
Modules Configuration
|
||||
*/
|
||||
|
||||
// plg-carousel
|
||||
c::set('plg_carousel.enable', true);
|
||||
c::set('plg_carousel.sort', 'sort'); // sortBy parameter: sort, title, etc.
|
||||
c::set('plg_carousel.dir', 'asc'); // sortBy direction: asc, desc
|
||||
c::set('plg_carousel.class', 'carousel-fade'); // additional class on top-most div
|
||||
|
||||
// plg-masonry
|
||||
c::set('plg_masonry.enable', true);
|
||||
|
@ -45,25 +37,18 @@ c::set('plg_masonry.sort', 'sort'); // sortBy parameter: sort, title, etc.
|
|||
c::set('plg_masonry.dir', 'asc'); // sortBy direction: asc, desc
|
||||
c::set('plg_masonry.lightbox', 'swipebox');
|
||||
|
||||
// bastians columns.php plugin from https://github.com/getkirby/plugins/tree/master/columns
|
||||
//c::set('columns.container', 'row');
|
||||
//c::set('columns.item', 'col-sm-6 columns');
|
||||
// columns plugin
|
||||
//c::set('kirby.columns.container', 'columns');
|
||||
//c::set('kirby.columns.item', 'column');
|
||||
|
||||
// enhanced sitemap by Jannik Beyerstedt:
|
||||
c::set('smap_ignoreSite', array('sitemap', 'error', 'home', 'qr', 'secret', 'test'));
|
||||
c::set('smap_ignoreTemplate', array('carousel', 'redirect'));
|
||||
c::set('smap_ignoreTemplate', array('redirect'));
|
||||
c::set('smap_showHiddenPagesAtRootLevel', true);
|
||||
c::set('smap_heading_visible', 'Hauptmenü');
|
||||
c::set('smap_heading_invisible', 'weitere Seiten');
|
||||
//c::set('smap_column_class_id', 'class="foo" id="bar"');
|
||||
|
||||
/*
|
||||
Piwik Plugin configuration
|
||||
*/
|
||||
c::set('spicy.piwik.active', false); /* cookie notice needed! */
|
||||
c::set('spicy.piwik.url', 'https://jannikb.aquila.uberspace.de/piwik');
|
||||
c::set('spicy.piwik.id', 2);
|
||||
|
||||
/*
|
||||
Routes
|
||||
*/
|
||||
|
@ -73,21 +58,5 @@ c::set('routes', array(
|
|||
'action' => function() {
|
||||
return site()->visit('sitemap');
|
||||
}
|
||||
),
|
||||
|
||||
// redirect legacy urls:
|
||||
// feature/webdesign -> webdesign
|
||||
// feature/fotografie -> fotografie
|
||||
// feature/fotografie/(:any) -> fotografie/(:any)
|
||||
array(
|
||||
'pattern' => 'feature/(:all)',
|
||||
'action' => function($uid) {
|
||||
if (site()->find($uid)) {
|
||||
$target = site()->find($uid)->url();
|
||||
header::redirect($target, 301);
|
||||
}else {
|
||||
go('error');
|
||||
}
|
||||
}
|
||||
)
|
||||
));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue