Skip to content
Grav 2.0 is officially stable. Read the announcement →

Community guidelines

Please keep discussions civil and on-topic. Repeated violations may lead to a temporary ban.

Themes & Styling

Disabling the date display from blog post

Started by Maciding Doson 9 years ago · 4 replies · 1318 views
9 years ago

How do I disable that date icon from the blog posts.
Antimatter theme

9 years ago

You mean the date in the top right in each blog post?

TWIG
<div class="list-blog-header">
    <span class="list-blog-date">
        <time class="dt-published" datetime="{{ page.date|date("c") }}">
            <span>{{ page.date|date("d") }}</span>
            <em>{{ page.date|date("M") }}</em>
        </time>
</span>

Just remove the span in

TXT
theme_folder/templates/partials/blog_item.html.tiwg.
👍 1
9 years ago

This should be done in a child theme then. Just copy over the template to your child theme with keeping the path to the template.

When overriding antimatter/templates/partials/blog_item.html.tiwg. you should have theme_folder/templates/partials/blog_item.html.tiwg. to override the template.

👍 1
9 years ago

No problems! @chris_jung is also right about the child theme. It did not occur for me to write it because it's something that always exists in every situation where you have to override script that is not yours.

Make sure you mark this post as answered, that way the forum will be more readable for searchers who try to find a solution.

Thank you:)

Suggested topics

Topic Participants Replies Views Activity
Themes & Styling · by Pedro M, 2 months ago
4 197 2 months ago
Themes & Styling · by Ian, 2 months ago
3 92 2 months ago
Themes & Styling · by Norbert, 2 years ago
11 454 3 months ago
Themes & Styling · by Lukáš Findeis, 3 months ago
0 47 3 months ago
Themes & Styling · by Sebadamus, 4 months ago
5 127 3 months ago