Support Forum
Hi All,
My forum is of a technical nature and I often need to post HTML snippets, shortcodes, Javascript snippets, etc., to demonstrate various how-to scenarios.
How can I post my code without it rendering?
Best,
Vic
Vic Dorfman - Membership Site Expert
Hey Vic,
Have you taken a look at the 'Syntax Highliter' plugin? Available from the Downloads page > Member Plugins.
My recommendation would be to use the tinyMCE rich text editor and install our Syntax Highlighter plugin. So - for example - a small section of php code I have been working with today would display like:
add_action('genesis_meta', 'sp_home_genesis_meta'); function sp_home_genesis_meta() { if (is_active_sidebar('content-top-left') || is_active_sidebar('content-top-right') || is_active_sidebar('content-bottom')) { remove_action('genesis_loop', 'genesis_do_loop'); add_action('genesis_loop', 'sp_home_loop_helper'); add_filter('genesis_pre_get_option_site_layout', '__genesis_return_full_width_content'); } }
Supports a variety of languages and, of course, your users can just use the raw code button and cut and paste.
YELLOW
SWORDFISH
|
I've installed this plugin and my TinyMCE editor is active.
But how do I make the Syntax Highlight button appear in my editor?
Here's my editor:
And here are my components settings:
Please advise.
Best,
Vic
Vic Dorfman - Membership Site Expert
1 Guest(s)