HTML5 Reference

HTML <ins> tag

Definition

The <ins> tag is used to define editorial insertions in text.

Example


  <p>Today is <del>Sunday</del><ins>Monday</ins>.</p>

Today is SundayMonday.

Attributes

The following attributes can be used with the <ins> tag.


<ins> Specific Attributes
Attribute Value Description Example
citeurlSpecifies a URL containing information regarding the insertion.

<ins cite="../pages/insertions.html">Editorial insertion</ins>
datetimeYYYY-MM-DDThh:mm:ssTZDSpecifies the data and optionally the time of the editorial insertion.

<ins datetime="2020-02-20">Editorial insertion</ins>
<ins> Global Attributes
Attribute Description Example
Common
classSpecifies a classname for the element allowing you to apply the style of the predefined class to the content.

<ins class="name">Editorial insertion text</ins>
idSpecifies a unique id for the element allowing you to apply the style of the predefined id to the content.

<ins id="name">Editorial insertion text</ins>
styleSpecifies an inline style for the element allowing you to apply the style to the contentt.

<ins style="color:red;">Editorial insertion text</ins>
titleSpecifies an inline style for the element allowing you to apply the style to the content.

<ins title="Content info">Editorial insertion text</ins>
Keyboard
accesskeySpecifies a keyboard shortcut to associate with the element.

<ins accesskey="a">Editorial insertion text</ins>
tabindexSpecifies a tab order for the element.

<ins tabindex="1">Editorial insertion text</ins>
Language
dirSpecifies the directional flow of the content.

<!-- The text will flow from left to right -->
<ins dir="ltr">Editorial insertion text</ins>
<!-- The text will flow from right to left -->
<ins dir="rtl">Editorial insertion text</ins>
langSpecifies a language code for the content of the element.

<ins lang="en">Editorial insertion text</ins>
spellcheckSpecifies an inline style for the element allowing you to apply the style to the contentt.

<!-- Valid values true and false. -->
<!-- Default inherited/browser specific. -->
<ins spellcheck="true">Editorial insertion text</ins> 
translateSpecifies an inline style for the element allowing you to apply the style to the content.

<!-- Valid values yes and no. -->
<!-- Default yes. -->
<ins translate="no">Editorial insertion text</ins> 
Miscellaneous
contenteditableSpecifies whether the content of the element is editable.

<!-- Valid values true and false. -->
<!-- Default inherited. -->
<ins contenteditable="true">Editorial insertion text</ins> 
draggableSpecifies whether the element is draggable.

<!-- Valid values true and false. -->
<!-- Default browser specific. -->
<ins draggable="true">Editorial insertion text</ins>
hiddenSpecifies whether the element is not yet, or no longer, relevant.

<!-- Valid values an empty string or hidden -->
<ins hidden>Editorial insertion text</ins> 
<ins hidden="hidden">Editorial insertion text</ins> 
<ins> Event Attributes
Attribute Description Example
Document Element
oncopyThe script to be run when the user copies the content of an element.

 <!-- Executes go() function -->
<ins oncopy="go()">Editorial insertion text</ins> 
oncutThe script to be run when the user cuts the content of an element.

 <!-- Executes go() function -->
<ins oncut="go()">Editorial insertion text</ins>
onpasteThe script to be run when the user pastes some content into an element.

 <!-- Executes go() function -->
<ins onpaste="go()">Editorial insertion text</ins>
Drag and Drop
ondragThe script to be run when an element is dragged.

 <!-- Executes go() function -->
<ins ondrag="go()">Editorial insertion text</ins>
ondragendThe script to be run when an element has stopped being dragged.

 <!-- Executes go() function -->
<ins ondragend="go()">Editorial insertion text</ins>
ondragenterThe script to be run when an element has been dragged to a valid drop target.

 <!-- Executes go() function -->
<ins ondragenter="go()">Editorial insertion text</ins>
ondragleaveThe script to be run when an element leaves a valid drop target.

 <!-- Executes go() function -->
<ins ondragleave="go()">Editorial insertion text</ins>
ondragoverThe script to be run when an element is being dragged over a valid drop target.

 <!-- Executes go() function -->
<ins ondragover="go()">Editorial insertion text</ins>
ondragstartThe script to be run at the start of a drag operation.

 <!-- Executes go() function -->
<ins ondragstart="go()">Editorial insertion text</ins>
ondropThe script to be run when a dragged element is being dropped.

 <!-- Executes go() function -->
<ins ondrop="go()">Editorial insertion text</ins>
Form
onblurThe script to be run when the element loses focus.

 <!-- Executes go() function -->
<ins onblur="go()">Editorial insertion text</ins>
onchangeThe script to be run when object changed and attempt to leave field.

 <!-- Executes go() function -->
<ins onchange="go()">Editorial insertion text</ins>
oncontextmenuThe script to be run when a context menu is triggered.

 <!-- Executes go() function -->
<ins oncontextmenu="go()">Editorial insertion text</ins>
onfocusThe script to be run when the element gets focus.

 <!-- Executes go() function -->
<ins onfocus="go()">Editorial insertion text</ins>
oninputThe script to be run when an element gets user input.

 <!-- Executes go() function -->
<ins oninput="go()">Editorial insertion text</ins>
oninvalidThe script to be run when an element is invalid.

 <!-- Executes go() function -->
<ins oninvalid="go()">Editorial insertion text</ins>
onresetThe script to be run when a dragged element is being dropped.

 <!-- Executes go() function -->
<ins onreset="go()">Editorial insertion text</ins>
onselectThe script to be run when some or all of the contents of an object are selected.

 <!-- Executes go() function -->
<ins onselect="go()">Editorial insertion text</ins>
onsubmitThe script to be run when a form is submitted.

 <!-- Executes go() function -->
<ins onsubmit="go()">Editorial insertion text</ins>
Keyboard
onkeydownThe script to be run when an element is in focus and keyboard key is pressed down.

 <!-- Executes go() function -->
<ins onkeydown="go()">Editorial insertion text</ins>
onkeypressThe script to be run when an element is in focus and keyboard key is pressed down and released.

 <!-- Executes go() function -->
<ins onkeypress="go()">Editorial insertion text</ins>
onkeyupThe script to be run when an element is in focus and keyboard key is released.

 <!-- Executes go() function -->
<ins onkeyup="go()">Editorial insertion text</ins>
Media
onabortThe script code to be run on abort.

 <!-- Executes go() function -->
<ins onabort="go()">Editorial insertion text</ins>
oncanplayThe script to be run when a file has buffered enough so it is ready to start playing.

 <!-- Executes go() function -->
<ins oncanplay="go()">Editorial insertion text</ins>
oncanplaythroughThe script to be run when a file can be played all the way to the end without further need of buffering.

 <!-- Executes go() function -->
<ins oncanplaythrough="go()">Editorial insertion text</ins>
oncuechangeThe script to be run when the cue changes when using the track element.

 <!-- Executes go() function -->
<ins oncuechange="go()">Editorial insertion text</ins>
ondurationchangeThe script to be run when the length of the media is changed.

 <!-- Executes go() function -->
<ins ondurationchange="go()">Editorial insertion text</ins>
onemptiedThe script to be run when a media resource element suddenly becomes empty, usually due to an error.

 <!-- Executes go() function -->
<ins onemptied="go()">Editorial insertion text</ins>
onendedThe script to be run when the media has reach the end.

 <!-- Executes go() function -->
<ins onended="go()">Editorial insertion text</ins>
onloadeddataThe script to be run when media data is loaded and playback can start.

 <!-- Executes go() function -->
<ins onloadeddata="go()">Editorial insertion text</ins>
onloadedmetadataThe script to be run when metadata has been loaded.

 <!-- Executes go() function -->
<ins onloadedmetadata="go()">Editorial insertion text</ins>
onloadstartThe script to be run whenthe media resource has started loading.

 <!-- Executes go() function -->
<ins onloadstart="go()">Editorial insertion text</ins>
onpauseThe script to be run when the media resource has been paused.

 <!-- Executes go() function -->
<ins onpause="go()">Editorial insertion text</ins>
onplayThe script to be run when the media resource starts playback.

 <!-- Executes go() function -->
<ins onplay="go()">Editorial insertion text</ins>
onplayingThe script to be run when when playback has already begun.

 <!-- Executes go() function -->
<ins onplaying="go()">Editorial insertion text</ins>
onprogressThe script to be run when the browser is fetching the media data.

 <!-- Executes go() function -->
<ins onprogress="go()">Editorial insertion text</ins>
onratechangeThe script to be run when the playback rate changes.

 <!-- Executes go() function -->
<ins onratechange="go()">Editorial insertion text</ins>
onseekedThe script to be run when the seeking attribute is set to false indicating that seeking has finished.

 <!-- Executes go() function -->
<ins onseeked="go()">Editorial insertion text</ins>
onseekingThe script to be run when the seeking attribute is set to true indicating that seeking is currently active.

 <!-- Executes go() function -->
<ins onseeking="go()">Editorial insertion text</ins>
onstalledThe script to be run when the browser is unable to continue fetching media data.

 <!-- Executes go() function -->
<ins onstalled="go()">Editorial insertion text</ins>
onsuspendThe script to be run when media data has stopped before being completely loaded.

 <!-- Executes go() function -->
<ins onsuspend="go()">Editorial insertion text</ins>
ontimeupdateThe script to be run when the media resources current playback position has changed.

 <!-- Executes go() function -->
<ins ontimeupdate="go()">Editorial insertion text</ins>
onvolumechangeThe script to be run when the volume has changed or been muted.

 <!-- Executes go() function -->
<ins onvolumechange="go()">Editorial insertion text</ins>
onwaitingThe script to be run when the media resource has paused but is expected to resume.

 <!-- Executes go() function -->
<ins onwaiting="go()">Editorial insertion text</ins>
Mouse
onclickThe script to be run when when a mouse is clicked on an element.

 <!-- Executes go() function -->
<ins onclick="go()">Editorial insertion text</ins>
ondblclickThe script to be run when a mouse is double clicked on an element.

 <!-- Executes go() function -->
<ins ondblclick="go()">Editorial insertion text</ins>
onmousedownThe script to be run when he mouse button is pressed down while the cursor is over an element.

 <!-- Executes go() function -->
<ins onmousedown="go()">Editorial insertion text</ins>
onmousemoveThe script to be run when the mouse button is moved.

 <!-- Executes go() function -->
<ins onmousemove="go()">Editorial insertion text</ins>
onmouseoutThe script to be run when the mouse cursor moves off an element.

 <!-- Executes go() function -->
<ins onmouseout="go()">Editorial insertion text</ins>>
onmouseoverThe script to be run when the mouse cursor moves over an element.

 <!-- Executes go() function -->
<ins onmouseover="go()">Editorial insertion text</ins>
onmouseupThe script to be run when the mouse button is released while the cursor is over the element.

 <!-- Executes go() function -->
<ins onmouseup="go()">Editorial insertion text</ins>
onwheelThe script to be run when the mouse wheel rolls up or down over an element.

 <!-- Executes go() function -->
<ins onwheel="go()">Editorial insertion text</ins>
Scroll
onscrollThe script code to be run when the scrollbar of an element is being scrolled.

 <!-- Executes go() function -->
<ins onscroll="go()">Editorial insertion text</ins> 
Window - NONE

Relevant HTML Tutorials

HTML Lessons - Inline Semantics