BACK TO DIRECTORY

Smart Code Escape

by danielpataki

5.0
(1 ratings)

A tiny plugin for WordPress which converts greater than signs, smaller than signs and ampersands to html entities within pre tags. It supports semantic syntax you would use when using the Prism highlighter for example. If a code tag sits immediately within a pre tag it will not be escaped.

Code is escaped before it is displayed which gives you easy editing access in the backend as you will always see the unescaped version.

Screenshots

Some code written in the admin. Notice, no need to encode entities

Some code written in the admin. Notice, no need to encode entities

This is how it is shown on the front-end. The initial code tag is not encoded for use in Prism.

This is how it is shown on the front-end. The initial code tag is not encoded for use in Prism.

Plugin Details

Active Installs
10
Total Downloads
2,301
Version
1.1
Requires WP
1.2.1
Requires PHP
Tested Up To
4.2.39
Added
2014-12-08
Last Updated
2015-04-22 4:37pm GMT

Ratings

5
1
4
0
3
0
2
0
1
0