How to remove "Welcome to" from header title on front page in Drupal 8
In drupal 7 you just add in page.tpl.php this part of code:
<?php if (!$is_front){
print render($page['content']);
} ?>
How to remove "Welcome to" from header title on front page in Drupal 8
In drupal 7 you just add in page.tpl.php this part of code:
<?php if (!$is_front){
print render($page['content']);
} ?>
In D8 frontpage is a view. To change title of the front page, go to admin/structure/views/view/frontpage, find Global: Title override link
Open it and it will allow to set or remove custom front page title.
<title>{% if not root_path %}{{ head_title.name }}{% else %}{{ head_title|safe_join(' | ') }}{% endif %}</title>
for the title tag. –
Lovins Default views with url /node we leave as it is.
In page.html.twig we output all blocks except content block:
{% if is_front %}
{{ page.content.breadcrumbs }}
{{ page.content.page_title }}
{{ page.content.local_tasks }}
{{ page.content.help }}
{{ page.content.local_actions }}
{#{{ page.content.content }}#} < no content
{% else %}
{{ page.content }}
{% endif %}
page-title.html.twig
{% if title %}
{# nothing #}
{% else %} {# for other pages #}
<h1{{ title_attributes.addClass('page-header') }}>{{ title }}</h1>
{% endif %}
© 2022 - 2024 — McMap. All rights reserved.