1. At the TinyMCE editor, click [Insert/Edit code sample] button to insert code.

2. Select the language you want to code.

3. Type in your code.

4. click [OK] to close the code editor.

5. The result is as below.

<h1>Heading1</h1>
<p>text</p>

6. If you want to add line numbers, click  at the lower-right of TinyMCE to view the source HTML code of the article. 

7. In the class block, add line-numbers, like the example below.

<pre class="line-numbers language-markup">

8. The result is as below.

<h1>Heading1</h1>
<p>text</p>

[Reference]  

PRISM (PRISMJS.COM) SYNTAXHIGHLIGHTER FOR JOOMLA!

Subcategories