Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix highlighting xml/html code by escaping html characters #30

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

anton-sergeev
Copy link

@anton-sergeev anton-sergeev commented Mar 15, 2017

Here is bug, no escape html characters:
redmine_highlightjs bug
After fix:
redmine_highlightjs fix

@anton-sergeev
Copy link
Author

This related to #18, #21, #26 Issues

@miloja
Copy link

miloja commented Aug 16, 2018

This is not a proper fix. You should check file extension and language given

@anton-sergeev
Copy link
Author

This is a common problem for html-like tags inside any language preformatted text. For example if I post the next:

<pre><code class="ruby">
some_string = "start <b>ddd</b>"
</code></pre>

I got the next result:
redmine_highlightjs bug
And with escaping suggested in this pull request:
redmine_highlightjs with_fix

@miloja
Copy link

miloja commented Aug 17, 2018

You're right. The fix is very ok. I haven't thought about HTML hidden in ruby string constant. :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants