I built a Markdown to oldschool BBCode tool a few weeks back, worked great on my macbook however trying to use it on Windows recently resulted in some strange output. Upon inspecting the HTML that blackfriday.Run output, it seems it's trying to escape double-backticks as quotes first.
Here's an example of the Markdown I'm trying to process:
For example, this:
```markdown
The Swiss Army Knife of SA:MP - vital tools for any server owner or library
maintainer.
## Overview
Server management and configuration tools:
* Manage your server settings in JSON format (compiles to server.cfg)
* Run the server from `sampctl` and let it worry about automatic restarts
* Automatically download Windows/Linux server binaries when you need them
```
becomes this:
```json
The Swiss Army Knife of SA:MP - vital tools for any server owner or library maintainer.
[COLOR="RoyalBlue"][size="6"][B]Overview[/B][/size][/COLOR]
Server management and configuration tools:
[LIST]
[*]Manage your server settings in JSON format (compiles to server.cfg)
[*]Run the server from [FONT="courier new"]sampctl[/FONT] and let it worry about automatic restarts
[*]Automatically download Windows/Linux server binaries when you need them
[/LIST]
```
And this is the output of blackfriday.Run:
For example, this:
“`markdown
The Swiss Army Knife of SA:MP - vital tools for any server owner or library
maintainer.
</p>
<h2>Overview
</h2>
<p>
Server management and configuration tools:
* Manage your server settings in JSON format (compiles to server.cfg)
* Run the server from <code>sampctl</code> and let it worry about automatic restarts
* Automatically download Windows/Linux server binaries when you need them
<code>
becomes this:
</code>json
The Swiss Army Knife of SA:MP - vital tools for any server owner or library maintainer.
[COLOR=“RoyalBlue”][size=“6”][B]Overview[/B][/size][/COLOR]
Server management and configuration tools:
[LIST]
[<em>]Manage your server settings in JSON format (compiles to server.cfg)
[</em>]Run the server from [FONT=“courier new”]sampctl[/FONT] and let it worry about automatic restarts
[*]Automatically download Windows/Linux server binaries when you need them
[/LIST]
“`
Notice the “ - I can't think why this only occurs on Windows, I tried to dig into it a bit but I'm not really sure what part of this library could even be platform dependent.
I built a Markdown to oldschool BBCode tool a few weeks back, worked great on my macbook however trying to use it on Windows recently resulted in some strange output. Upon inspecting the HTML that
blackfriday.Run
output, it seems it's trying to escape double-backticks as quotes first.Here's an example of the Markdown I'm trying to process:
And this is the output of
blackfriday.Run
:Notice the
“
- I can't think why this only occurs on Windows, I tried to dig into it a bit but I'm not really sure what part of this library could even be platform dependent.This is the tool if anyone wants to check the code or try and reproduce the possible bug: https://github.com/Southclaws/forumfmt