On this site (and many other message boards I visit) if I want to make a word italicized I code < i >, Or bold < b >, or underlined < u >. But if I want to quote rather than < q > I have to write out the whole word. Why?
If you’re using angle brackets, that’s typically seen in HTML which doesn’t have a <quote> tag, but uses <blockquote> instead. Some software, such as Discourse, partially recognize HTML tags. There is a short quote <q> in the HTML specification, but it isn’t supported universally and typically just puts double quotes around the text when it is.
If you’re using brackets, what you’re seeing is BB Code, which I’m pretty sure originated with UBB (Ultimate Bulletin Board), but was adopted by most forum software providers and was likely heavily influenced by HTML.
As for why some tags are single letters and some are not, you’ll need to ask Tim Berners-Lee why he chose <b> for bold and <blockquote> for quoting.
And then there’s Markdown which lets you make bold by surrounding text with two asterisks like **bold** and italics by using one asterisk like *italics* .
What you get in Discourse is the unholy overlap of some subset of HTML, some subset of BBCode and some subset of some unknown variant of Markdown. And each of the three isn’t totally internally consistent either.
Which is not to say that’s evil; just that if you’re seeking consistency you’re in totally the wrong place.
Is there any place where I can find out what Discourse actually recognizes?
This post on the Discourse forums from @codinghorror describes the basics, although it certainly isn’t a reference (I don’t believe there is one for this). We also covered a lot of the cool stuff in this thread on ATMB.
I also found this unofficial guide.
Discourse supports standard Markdown.
(Markdown includes support for a number of html tags.)
Discourse also includes support for a few BBCode tags. See this post by CodingHorror:
Okay, I am going to try something in that guide:
$$H(z)&=\sum_{k=0}^{n+1}z^{nk}$$
Nope, didn’t work. Latex is my native language, so that would’ve been great.
There is a Math plugin for Discourse which would allow that, but it isn’t installed here. (Yet )
My mind went somewhere utterly else than formatting.
It’s also fun to do a Google search for LaTeX when the head of the company is looking at your screen. Thanks to past searches, the text results were fine. Trying to show screenshots, on the other hand…
I asked for it in this post and even tagged Ed, but I’m assuming this is not on their short-list of things to take care of in the near future.
What kind of hackery failed to throw an error when the alignment symbol & was used outside of an aligned environment? I’m surprised the DigiKey forum allowed that post to go uncorrected for so many years.
It’s possible that I deleted the alignment symbol to get it to work. But what will really bake your noodle is that it renders correctly even with a final unclosed brace, and that the unclosed brace is crucial for it working in Discourse.
Yes, I wondered that too, but I just copied (part of) their example. Actually that line ended in \\ which I took to mean that somehow an array environment was default. Incidentally, I had to type \\\ to get a double backslash (and five of them to get three).
Bottom line: We still don’t have any real documentation of the Discourse syntax.
True, but basically it’s just Markdown, and you can check any Markdown reference.
99% of the time Markdown is all you really need.
If you want something more fancy, there’s ‘some’ html –
This is a kbd tag
green
pinkish
The only way to underline seems to be to use BBCode.
Yes, as @GreenWyvern noted, mostly the native language is Markdown, so refer to the official reference:
Cheatsheet
https://commonmark.org/help/
Interactive tutorial
https://commonmark.org/help/tutorial/
A whitelisted subset of HTML tags is also supported, such as <ins>
, <del>
, <mark>
, <sub>
, <sup>
, <s>/<strike>
… as well as the duplicate stuff like bold, italic… in general you should favor markdown as the “native markup language” of Discourse, but understand that markdown was always designed to live in harmony with HTML, too!
I think it’s more useful to phrase this in terms of needs… what do you need to do? What is your goal? What do you intend to accomplish? Answering those questions will allow me to give you the most relevant information.
(I would strongly advise against enabling $
style math markup here, it’s quite a bit of complex overhead for a site that isn’t fundamentally about mathematics… now if you want to try it out on https://mathoverflow.net/ or https://math.stackexchange.com/ go for it!)
What overhead? Most users won’t use it. The MathJax plugin, which Discourse already supports (but isn’t enabled here) renders everything on the client. Should be negligible server-side overhead.
There’s no shortage of math-inclined people here. And our general questions subforum in particular gets many math questions, many of which would be better answered with LaTeX support. I know I’d post on more math related topics if it were supported, just because sometimes writing formulas with just sup/sub can get very annoying.