Hi @jlwp123!
In the Classic Editor, are you working in the Visual tab or the Code tab when you notice this behavior?
To help us better reproduce the issue, could you please share the exact HTML code you’re using in the post where the highlighting and line numbers aren’t showing? That will help us test it on our side.
Thread Starter
Jlwp
(@jlwp123)
Hi, thanks for your reply.
In the Classic Editor, I am working in the Code tab. I dont expect syntax hiliting in the Visual tab,
I tried some very simple code and still have the issue. There is no hiliting and no line numbers.
Complete code in Classic Editor:
<!-- wp:html -->
<h2>Hello</h2>
<script>
alert("Hello, World!");
</script>
<!-- /wp:html -->
Same code in HTML block:
<h2>Hello</h2>
<script>
alert("Hello, World!");
</script>
Thanks
Hi @jlwp123,
Have you tried enclosing your code with the
[code]
shortcode? For example:
[code]
<h2>Hello</h2>
<script>
alert("Hello, World!");
</script>
[/code]
Your code appears to be working properly on my test site once wrapped in the shortcode. I’ve attached a screenshot below showing how it appears on my end.
https://d.pr/i/xkmYlo
-
This reply was modified 6 days, 18 hours ago by
thabotswana.
-
This reply was modified 6 days, 18 hours ago by
thabotswana.
-
This reply was modified 6 days, 18 hours ago by
thabotswana.
-
This reply was modified 6 days, 18 hours ago by
thabotswana.
Thread Starter
Jlwp
(@jlwp123)
Hi I looked at your screenshot and ALL code is in black – so it is NOT working.
I really do not know what you mean when you say it is working.
Also I do not think that a shortcode should be added – plus this is not helping.
if you look at the feature image (the very top image) of the plugin homepage – you will see that various code is shown in various colors. Eg “echo” is shown in red. Are you familiar with what the plugin is supposed to do? It is supposed to show various parts of code in different colors – this is what hiliting means – your screenshot does not show that.
You’re right — the code is showing up all black and that’s not working as expected. I’ve escalated this to our developers (I’ve included your example code, screenshots, and the details you shared) so they can investigate.
Hi @jlwp123. I’ve logged this in our tracking systems to look into as soon as we can, but provided this context, it might not be right away. We’ll get back to you when we have a chance to reproduce and figure this out. 🙂
Thread Starter
Jlwp
(@jlwp123)
@thabotswana and @stephdau – Thank you for your replies. I was sorry to read about Alex and I appreciate any work you may be able to do on this when your time allows.
I think it may be helpful for you to know that I have the same issue with the Enlighter – Customizable Syntax Highlighter plugin – ie this may be more of a WP issue than an issue with your plugin.
Thanks for your understanding, and this will probably be very valuable extra info. 🙂