Why Use the Embed Manager?
TinyMCE routinely strips<iframe> tags and custom <script> blocks from content on save — this means pasting a YouTube embed or third-party widget directly into the editor will cause it to disappear.
The Code Embed Manager solves this by:
- Storing embed code in the database instead of in the editor body.
- Inserting it only at render time via shortcode — the editor never sees or processes the raw HTML.
- Single-source updates — edit the embed record once and every page that embeds it reflects the change immediately, without re-editing each page.
Admin Routes
The list view includes: inline search, type filter, active filter, shortcode preview badge, and type badge for quick identification.
Embed Types
Shortcode Syntax
Rendering Behavior
Step-by-Step: Adding a New Embed
1
Open Code Embeds
Go to Admin → CMS → Code Embeds (
/admin/cms-embeds).2
Create New Embed
Click the New Embed button.
3
Enter Internal Name
Give the embed a descriptive internal name (e.g. “Homepage Hero Video”, “Support Chat Widget”).
4
Select Embed Type
Choose YouTube, Vimeo, or Other HTML from the type dropdown.
5
Paste Embed Code
Paste the full embed code (e.g. YouTube
<iframe> snippet, Vimeo player code, or custom widget script) into the Code Snippet textarea.This textarea is not connected to TinyMCE — the raw HTML is stored exactly as entered, including iframes and scripts.
6
Save
Click Save Embed. A shortcode badge is generated and displayed.
7
Copy and Paste Shortcode
Copy the generated shortcode (e.g.
[code-embed:3]) and paste it into any CMS page body, sidebar, or product description.