This commit is contained in:
armansansd 2022-05-10 15:04:40 +02:00
parent f309248ee5
commit 3d20968197
3 changed files with 15 additions and 1 deletions

File diff suppressed because one or more lines are too long

View File

@ -13,7 +13,19 @@ use Drupal\Core\Url;
// }
function popsu_preprocess_html(&$variables) {
$node = \Drupal::routeMatch()->getParameter('node');
// $type = $node->getType();
//
$frontpage = \Drupal::service('path.matcher')->isFrontPage();
$variables['head_title']['slogan'] = \Drupal::config('system.site')->get('slogan');
//var_dump($variables['head_title']);
if( $frontpage == true){
$variables['head_title'] = $variables['head_title']["name"]." | ".$variables['head_title']['slogan'];
}else{
$variables['head_title'] = $variables['head_title']["name"];
}
if ($node){
if($node->hasField('field_programme') && $node->get('field_programme')->getString() != ""){
$variables['attributes']['class'][] = 'programme-' . $node->get('field_programme')->getString();

View File

@ -145,6 +145,8 @@
column-gap: 10px;
&>div[id='']{
height: 100%;
font-size: 0;
}