#2655 closed defect (bug) (maybelater)
Code blocks escaped with backticks are not parsed in FAQ?
Reported by: | GamerZ | Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Component: | Plugin Directory | Keywords: | |
Cc: |
Description
I am not sure whether it is my mistake.
But I have a few code blocks which are escaped by backticks as a FAQ. You can take a look at the readme.txt in SVN https://plugins.trac.wordpress.org/browser/wp-polls/trunk/readme.txt (right at the end)
But when it is parsed https://wordpress.org/plugins/wp-polls/ (expand the "To Display Total Polls"), only the bullet point is being parsed.
Is it a bug or my mistake?
Change History (10)
#3
@
8 years ago
@dd32 does it now supports markdown better?
I have a parser to convert GitHub README.md to WordPress readme.txt. This is the original README.md https://github.com/lesterchan/wp-polls/blob/master/README.md
Will it work if I just use this readme and paste it over to WordPress readme.txt since it is better supported?
#5
follow-up:
↓ 6
@
8 years ago
@GamerZ Can't hurt to try the original form. I have seen authors using more or less unaltered markdown, including such things as # headers. Seems to work fine in the new directory.
#6
in reply to:
↑ 5
@
8 years ago
Replying to Otto42:
@GamerZ Can't hurt to try the original form. I have seen authors using more or less unaltered markdown, including such things as # headers. Seems to work fine in the new directory.
Thanks. I tested, it works fine. But the bug still persists despite using GH Markdown. Can't have code in a bullet point
This ticket was mentioned in Slack in #meta by ipstenu. View the logs.
7 years ago
#9
@
21 months ago
It looks like code blocks with single backticks in a readme.txt are parsed correctly:
https://wordpress.org/plugins/cachify/#the%20cache%20folder%20is%20indexed%20by%20search%20engines%21
https://plugins.svn.wordpress.org/cachify/tags/2.3.2/readme.txt
But if you use a readme.md (which is also parsed as readme.txt replacement) and use three backticks (code block) it breaks:
https://wordpress.org/plugins/spcl/#does%20it%20matter%20whether%20a%20url%20is%20http%20or%20https%3F
https://plugins.svn.wordpress.org/spcl/tags/1.0.1/README.md
Looks like the Markdown parser is getting confused a bit here - but also that it's being more strict than the previous one.
Although it previously worked, code blocks are not supposed to be surrounded by a single backtick, instead according to the Markdown syntax they're supposed to be indented (ie. see how github parses that readme)
We're using Markdown Extra which adds extra syntaxes, such as fenced code blocks which should help here.
There might be something else happening here though, because even after changing it to a fenced code block, it still choked returning the following, note the unescaped
<?php
.I'm not sure if this is being caused by the fact it's within a list element, or if the library simply can't process code blocks properly.