Jump to content

Template:Tooltip

Checked
From Wikinews, the free news source you can write!


[edit] Template documentation

The Tooltip template adds a tooltip (hover text) to a piece of text. When a user hovers over the text, the tooltip displays additional information, providing context or explanations without cluttering the page.

Usage

[edit]
{{tooltip|Text to display|Tooltip message}}

Parameters

[edit]
  • Text to display (required): The text that will be visible on the page.
  • Tooltip message (required): The message that appears when the user hovers over the text.

Example

[edit]
{{tooltip|Click here|This is a tooltip message.}}

Result: Click here

Notes

[edit]
  • The tooltip appears when hovering over the text.
  • The text has a dotted underline (`border-bottom:1px dotted;`) to indicate that it has additional information.
  • The `nowiki` tag inside the template ensures that any wiki markup in the tooltip message is not parsed.