HTML Tags

HTML5 <mark> Tag

Topic: HTML5 Tags ReferencePrev|Next

Description

The <mark> element defines a marked section of text. You can use this tag if you want to highlight a section of your text for reference purposes.

The following table summarizes the usages context and the version history of this tag.

Placement: Inline
Content: Inline, and text
Start/End Tag: Start tag: required, End tag: required
Version: New in HTML5

Syntax

The basic syntax of the <mark> tag is given with:

HTML / XHTML: <mark> ... </mark>

The example below shows the <mark> tag in action.

<p>This is some <mark>highlighted</mark> text.</p>
<p>Here are <mark>some more highlighted</mark> text.</p>

Tag-Specific Attributes

The <mark> tag doesn't have any specific attribute.


Global Attributes

Like all other HTML tags, the <mark> tag supports the global attributes in HTML5.


Event Attributes

The <mark> tag also supports the event attributes in HTML5.


Browser Compatibility

The <mark> tag is supported in all major modern browsers.

Browsers Icon

Basic Support—

  • Firefox 4+
  • Google Chrome 6+
  • Internet Explorer 9+
  • Apple Safari 5+
  • Opera 11.1+

Further Reading

See tutorial on: HTML Text Formatting.

Related tags: <b>, <code>, <del>, <em>, <i>, <ins>, <small>, <strong>, <sub>, <sup>.

Bootstrap UI Design Templates Property Marvels - A Leading Real Estate Portal for Premium Properties