EnlighterJS / Plugin.WordPress

:package: Official WordPress Plugin of EnlighterJS
http://wordpress.org/plugins/enlighter/
GNU General Public License v2.0
115 stars 17 forks source link

</string> are shown automatically #354

Closed kensoftphDOTcom closed 1 year ago

kensoftphDOTcom commented 1 year ago

Describe the bug I am writing a blog post on my website. I have a java code which includes ChoiceBox cb = new ChoiceBox<>(); something like that and there is no problem in the text editor but when I preview the post, it shows the end or closing tag at the end of the code snippet like this: it should not supposed to show a closing tag like that.

Website url: *****

WordPress Editing Mode Using the Classic text editor - No problem. Screenshot_1

AndiDittrich commented 1 year ago

sry but first of all, please provide website link without fu**** ad overlay!

to reproduce your issue i need much more details: which editing method you'r using ? shortcodes (which filter: enlighter or legacy) or raw html ?

such issues are mostly caused by non-escaped html specialchars using raw html editing mode or WordPress shortcode handler

kensoftphDOTcom commented 1 year ago

Sorry, I didn't mean to. I just included the URL because I wonder if that could be helpful if you inspect it. Not intended to show ads on your side. I'm so sorry about that, and thank you for removing the URL to avoid others from viewing it.

Please see the attached screenshots; these might help you and I have no idea what you mean by editing method and filters you're looking for. I just use what I see in the classic text editor. 1 2 3 4 5 6 7 8

kensoftphDOTcom commented 1 year ago

This code will generate 2 closing string tags when it's being previewed. Just like I provided on the question. Screenshot_2

AndiDittrich commented 1 year ago

i'm confused... there is no "preview" function build into the TinyMCE editor (classic editor) - imho thats caused by a 3rd party plugin. please try it within a clean install

kensoftphDOTcom commented 1 year ago

Sorry for the confusion. Please take a look at the screenshots.

The first screenshot is currently editing, and the second screenshot is being previewed or output. Screenshot_1 Screenshot_2

AndiDittrich commented 1 year ago

just for clarification: you're using the Gutenberg editor with a "Classic" Block, then adding EnlighterJS codeblock via TinyMCE Buttons ? btw. this editing "method" shouldn't be used - there is a native Gutenberg integration/blocks available for EnlighterJS


atm i'm unable to reproduce this issue within the testing environment - it must be a third party plugin/theme or page builder issue

kensoftphDOTcom commented 1 year ago

Correct.

Thank you very much for your response. Maybe it was a third party plugin issue, and I'm going to investigate this next time.

kensoftphDOTcom commented 1 year ago

Hello, I tried the EnlighterJS block to add Java codes just like I showed to you and the issue is still the same.

kensoftphDOTcom commented 1 year ago

I didn't use the TinyMCE.

AndiDittrich commented 1 year ago

i strongly believe that you're experiencing this issue but i'm unable to reproduce the issue within the dev env.

could you please try it in a clean wordpress enviroment (standard theme, Enlighter plugin - nothing else) - if this is working it's a third party issue (in 99% of all similar cases that was the root cause). to identify the weak theme/plugin enable/disable the others one by one

kensoftphDOTcom commented 1 year ago

Oh, I'm sorry. I forgot about the third party issue, my bad. What I did was to try the Enlighther block and didn't investigate the issue by disabling those third party plugins. I will investigate this next time and will update you if the issue persists.