How to add html markup to TinyMCE & JCE editor (without plugin)

jce code option

 It can be frustrating if you want to add a simple piece of HTML code to an article in Joomla without your pesky editor of choice stripping it out when you hit the save button. So, here's a really simple way to add your HTML markup inside your Joomla article without it disappearing.

1. Add HTML markup to Joomla's JCE editor.

Although you can nip on over to Github and get a plugin to do the job, it isn't necessary if you just want a basic solution. First, you'll need to switch to the "code" option in JCE (see lead image above).

Next, simply type the following code into the html 

language markup

 and switch back to see the results.


<pre class="language-markup"><code>Your code goes here</code></pre>


Add HTML markup to Joomla's Tiny MCE editor.

It's a tad easier with Joomla's default editor, TinyMCE. Simply click on the icon that you see in the image below and paste your code into the box that pops up and you should be all done :) 

 Add HTML markup to Joomla TinyMCE editor