How to use HTML Title Module
Last updated on
29 November 2022
This documentation needs review. See "Help improve this page" in the sidebar.
- Go to admin/config/user-interface/html_title and mention the element tags that you want to use in your title field like div, span, etc.
NOTE: If you don't mention the elements then you won't be able to use them. - Click on save configuration button.
- After that, edit any content and add element to Title field. E.g.
<div>My Title</div> - Can also add class in title field e.g.
<div class="title">My title</div> - Inspect the the title field after saving the changes and you will notice that My Title is wrapped in <div> element.
NOTES:
- This module is used when the node template is rendering page title field. Without this module, the element tags will also get rendered with title value.
- Don't forget that for this to work you need to go to the "Manage Display" tab of the content type and select the "HTML-title text" format for the title field.
Help improve this page
Page status: Needs review
You can:
You can:
- Log in, click Edit, and edit this page
- Log in, click Discuss, update the Page status value, and suggest an improvement
- Log in and create a Documentation issue with your suggestion