Wordpress - Show shortcode without executing it
To display a shortcode instead of rendering it you have two options:
- Write
[[shortcode]]
. WordPress will show this as[shortcode]
. - Escape the
[
, write it as as[
or[
.
Using [
tag will not work if you switch between the text and visual editor.
The [[shortcode]]
solution does not work either with WP 4.1.1.
Instead, the following solution works:
[[shortcode]
Hello World
[/shortcode]]
Worked for me:
[shortcode]
where [
is [ and ]
is ] html codes.
Don't worked for me the one suggested by toscho: Write [[shortcode]]. WordPress will show this as [shortcode].