On my WordPress blog I am using the wp-sytax plugin to format a code snippet.
In the HTML view I have the following code:
<pre lang="c">
#include<stdio.h>
</pre>
But in the regular view it shows:
#include<stdio.h>
How can i make #include<stdio.h>
appear as I typed it?
Add
escaped="true"
, to tell the engine that the code shouldn’t be converted to entities:(See example 4 of the Documentation)
You need to modify the plugin slightly and escape the characters as described in this post.
The escaping above is done using htmlspecialchars_decode.