Archived topic
HTML Editor Syntax Highlighter
11 replies · Started by Alain Aubry on April 12, 2020
Hi
I am using "HTML Editor Syntax Highlighter" plugin. It has worked 100% everywhere, except when I enable "sections" in a page.
Is there any way of enabling it in that particular case.
Thanks
Hi there,
Are you just starting to build the site?
If so I would highly recommend using our upcoming block plugin GenerateBlocks to achieve the layout you are going for:
https://generateblocks.com/
It’s currently in Beta testing but we are moving along nicely and getting ready for the official release soon:
https://generateblocks.com/install/
One of the main goals of the plugin is to replace the old Sections add-on which won’t be getting any updates now.
Hi Leo
Thank you for the heads up, I will definitely take a look at the new plugin.
Now, answering your question: no, it is an old site and in a few pages I use "sections", but when I do I cannot see the Syntax Highlighting. It would be nice.
Also, I have a similar problem when using Gutenberg, the Syntax Highlighting plugin works fine, but the Wordpress design allows for a narrow "code editor" screen, just 580 px, while the normal "visual" editing screen is 1160 px.
Up to now I have disregarded the use of Gutenberg because it is difficult to edit html. I normally edit the html and many time I add some inline css.
Thanks
Sections won't be getting any updates anytime soon unfortunately.
What does the plugin do? Maybe we could use some CSS as a workaround?
Can you link me to an example?
Hi Leo
The plugin highlights the HTML syntax, just like editing in Atom or Sublime, you see the opening and closing tags, the links, images, etc.
Take a look: https://wordpress.org/plugins/html-editor-syntax-highlighter/
Before discovering it, I was moving chunks of text to Atom, back and forward.
Thank you, Alain
Looks pretty cool. I'm not sure if it's possible to integrate with Sections - it depends on how they're initiating their plugin. I assume they're only targeting the core editor (why wouldn't they), which is why it isn't initiating within our Section editors.
Hi Tom
I am happy you like it.
I can open a ticket with them, but we need to give them some information.
Thanks, Alain
I'm going to assume there isn't much they can do. We're using the wp.editor javascript library in WordPress to initialize the Sections.
If there's a way to hook/filter into their plugin and apply it to our Sections, I'd be happy to take a look. However, Sections is likely a module that will go away at some point with the emergence of the new editor/GenerateBlocks.
Hi
I passed along your question about the hook/filter.
If in the future the Sections module has to go away, the few pages I use it can be converted to something else.
I will try your GenerateBlocks plugin, it seems VERY interesting.
Thank you
Alain
Frank says it is too much work and he is already creating a new version.
The answer is here: https://wordpress.org/support/topic/compatibility-with-generatepress-theme-2/
I am closing this.
Thank you all.
I figured as much. Let me know if any info is needed once the new version is out :)
You are so supportive!
The new version has been in the works for about a year... Maybe this little push gave him the needed energy!!!