Skip to content
● Meet Grav Guard: keep every Grav site you run secure and up to date, all from one place. Free for up to 3 sites. Read more →

How to disable all Markdown processing except newlines?

Solved by Martin View solution

Started by Martin 5 years ago · 3 replies · 989 views
5 years ago

Hello, Gravitons :)

I'm using my Grav Quark-theme blog to publish some of my poems and short stories. Markdown messes things up when I have dialogs with dashes etc. symbols that have special treatment in Markdown.

I tried to turn Markdown off for those blog items, but then it removes all the newlines and I would have to use HTML br to get them back. Currently, I have the global setting auto_line_breaks = true and it works really well to have proper newlines for my texts.

I really don't want to adjust my stories and poems to Markdown syntax, it would be a bit too much work.

Is there any way to configure Markdown to ignore everything except newlines? I would also appreciate coding-related advice, I'm not afraid of doing some PHP/yaml/twig stuff if needed.

5 years ago

I believe you're using a minus sign (-) and not the actual dash (–), correct?

5 years ago

Yes, some of my texts have minus signs. It depends on inspiration, I guess - sometimes I write things in Word (which tends to replace minus with dash) and sometimes in any text editor I have available.

5 years ago Solution

As a workaround, I installed TinyMCE plugin. I was afraid that it could potentially break things, but it turned out to work pretty well.

👍 1

Suggested topics

Topic Participants Replies Views Activity
Content & Markdown · by Jochen, 1 year ago
6 1662 1 year ago
Content & Markdown · by Ton Haarmans, 2 years ago
10 1234 2 years ago
Content & Markdown · by Jan L'Am, 2 years ago
4 1098 2 years ago
Content & Markdown · by Leonardo, 2 years ago
3 1001 2 years ago
Content & Markdown · by belthasar, 2 years ago
4 1491 2 years ago