Textbox.io 2.x Documentation : editor.content.insertHtmlAtCursor()

Insert HTML content at the cursor position with editor.content.insertHtmlAtCursor(). 

Content is inserted at the last known cursor position, regardless of whether the editor has focus.

Example

editor.content.insertHtmlAtCursor(html)
// Insert a string of HTML at the cursor position
var newContent ="<p>Any HTML Content</p>";
editor.content.insertHtmlAtCursor(newContent);

Parameters

htmlStringA string of HTML that will be inserted at the last known cursor position.

Returns

No return value.