When creating or managing an article, there may be instances where you want to hide certain information, such as the agent profile icon or details about who last updated the article and when:
To achieve this, you'll need to update the HTML template for articles. Follow these steps:
Navigate to Admin > Help Center > Help Center Design > Open Template Editor.
In the Template Editor, locate and open the template named ‘view.html’ (Articles).
Once the template is open, search for the code section between lines 150 and 160 and remove the code.
<div class="col-sm-10"> {% include 'Theme:PublishCommon:post-avatars.html.twig' with { item: article } %} <div class="dp-po-post-info"> <ul class="dp-po-post-info-list"> <li class="dp-po-post-info-item"> {{ phrase('helpcenter.general.last_update_by', {date_updated: article.last_revision.created_at | default(article.date_created), person_name: article.last_author.display_name_user}) | raw }} </li> </ul> </div> </div>
Save the template. After saving, the specified information will no longer be displayed in your article.
Additionally, if you'd like to remove the panel displaying the Author, Creation Date, Last Update, and Publish Date, locate the relevant code in the template:
If no previous changes have been made to the template, you can find the code on line 262, highlighted in a green box:
['Theme:PublishCommon:meta.html.twig']
.
After making these changes, the page will appear as shown below:
Dodaj komentarz
Zaloguj lub zarejestruj się, by złożyć komentarz.