Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Hi
The linked logo part of the theme always seem to be empty for me what ever I do.
In preprocess page in base theme the $logo variable is also always empty so the logo_img variables is never populated.
$variables['logo_img'] = '';
if (!empty($variables['logo'])) {
$elements = array(
'#theme' => 'image',
'#attributes' => array(
'src' => $variables['logo'],
'alt' => strip_tags($site_name) . ' ' . t('logo'),
'title' => strip_tags($site_name) . ' ' . t('Home'),
'class' => array('logo'),
)
);
$variables['logo_img'] = $elements;
}
Comment | File | Size | Author |
---|---|---|---|
#3 | fix_logo_variable-2638000-3.patch | 723 bytes | abu-zakham |
Comments
Comment #2
Strutsagget CreditAttribution: Strutsagget commentedSeems like drupal want us to use the new block instead.
Maybe we can find some inspiration from here https://www.drupal.org/node/2472127
Comment #3
abu-zakham CreditAttribution: abu-zakham at Vardot commentedHello, this patch fixed issue.
Thanks
Comment #5
samuel.mortensonThanks for the issue/patch, I committed something similar to #3 but changed the variable and render array to match the code in \Drupal\system\Plugin\Block\SystemBrandingBlock.