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

Bold and italics within code blocks aren't recognized #57

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

Conversation

fmarier
Copy link
Contributor

@fmarier fmarier commented Nov 5, 2012

Pass them through as raw HTML instead.

Pass them through as raw HTML instead.
@aaronsw
Copy link
Owner

aaronsw commented Nov 5, 2012

What's the use case for this? I'm having trouble understanding why you'd want this result.

@fmarier
Copy link
Contributor Author

fmarier commented Nov 5, 2012

That patch (and the other ones) comes from my Blogger-to-Ikiwiki conversion script.

On my blog, I've got code samples where I highlight particular pieces by making them bold or italics.

@aaronsw
Copy link
Owner

aaronsw commented Nov 5, 2012

Yeah, but in standard Markdown indented HTML tags get escaped. So this doesn't seem like it would help. Is this not true with ikiwiki?

@fmarier
Copy link
Contributor Author

fmarier commented Nov 5, 2012

Hm, you're right. I just tried it with the normal markdown cli tool and the above test case produces this mess:

<p>This is a <b>bold</b> statement.</p>

<pre><code>This is a &lt;i&gt;foreign&lt;/i&gt; word.
</code></pre>

which isn't even consistent.

In the ikiwiki parser, it lets these tags through. In fact I have more hacks that take advantage of that.

pombredanne pushed a commit to pombredanne/html2text that referenced this pull request Oct 10, 2015
Retain escaping of html except within code or pre tags.

Thanks Scott Blackburn @smblackburn
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