Skip to content
Grav 2.1 is out: every page speaks Markdown. Read the announcement →

Replace "grav site title" with image logo on Hypertext theme?

Solved by Miguel View solution

Started by Miguel 2 years ago · 5 replies · 442 views
2 years ago

Does anyone know how to replace the text site title name on the theme Hypertext with an image logo?

Thanks

2 years ago

I think you should read the forum guidelines and then consider posting your question again or maybe asking it elsewhere.

2 years ago Solution

Here's the solution I figured out:

go to user/themes/hypertext/templates/partials/page/header.html.twig

Replace

TWIG
{% else %}
  <h1><a href="{{ home_url }}">{{ site.title|e('html') }}</a></h1>
{% endif %}

With

TWIG
{% else %}
  <h1><a href="{{ home_url }}"><img src="{{ base_url_relative }}/user/images/logo.png" /></a></h1>
{% endif %}
👍 1
2 years ago

@rvlv, Please know that changes should never be made in a published theme/plugin. Your changes will be lost once a new version is released by the author.

Use an inheriting theme instead.

👍 1
2 years ago

Oh, you mean Grav automatically updates the theme? Thanks for the solution, will look into it.

2 years ago

@rvlv, No, Grav will do nothing automatically, but Admin will notify you if new versions have arrived. When hitting 'Update' themes/plugins will be overridden.

Suggested topics

Topic Participants Replies Views Activity
Themes & Styling · by FrViPofm, 13 hours ago
1 25 34 minutes ago
Themes & Styling · by stuart young, 1 month ago
3 480 1 month ago
Themes & Styling · by Sebadamus, 2 months ago
5 481 2 months ago
Themes & Styling · by martynfoster735, 2 months ago
1 460 2 months ago
Themes & Styling · by Justin Young, 2 months ago
1 490 2 months ago