Markdown cheat sheet

Started by LociOiling

LociOiling Lv 1

I found this Markdown cheat sheet. It's a little easier to digest than the full syntax.

The new Discussion boards use Markdown syntax.

Several things don't seem to work in the Foldit implementation.

  1. a task list doesn't indicate the "checked off" items indicated in the markup
  2. emojis don't get rendered
  3. highlights aren't recognized, but asterisks can fill in
  4. subscripts are ignored
  5. superscripts aren't so super

Here's a test of the items from the cheat sheet:

Basic syntax

Heading

This list uses heading 1 and heading 2.

heading 3

Heading 3 is also available.

Heading 4

How many levels do you really want in your hierarchy?

bold text

bold text

blockquote

This is an example of a blockquote, where you copy something from some other web page.

ordered list

  1. An ordered list
  2. is just a list
  3. of numbered items.

code (single line)

for ii = 1, structure.GetCount() do

horizontal rule:


link

Once again, see the Markdown cheat sheet.

image

Images get created by dragging an image file to your post. This creates the necessary HTML-style markup. The Markdown image markup might be used for external images.

Extended syntax

table

table column 1 table column2
keyword 1 value 1
keyword 2 value 2

fenced code (multiple lines)

for ii = 1, structure.GetCount () do
   -- then a miracle occurs
end

footnote

Here's a sentence with a footnote, adapted from the cheat sheet. 1

definition

alanine
one more carbon than glycine

strikethrough

The old Foldit website.

task list

  • create new website
  • create Windows 64-bit client
  • update Mac and Linux clients
  • get everything working perfectly

emoji

An emoji like :joy: brings only sorrow.

highlight

A sentence with ==highlighted words==. The suggested Markdown markup doesn't work, but plain old asterisks can still do the job.

subscript

No sub:

H~2~O

superscipt

No super:

X^2^


  1. This is the footnote, and it's really at the foot. 

LociOiling Lv 1

HTML tags can be used for some of the problem items, although it's a little more effort than the Markdown equivalent.

The HTML "mark" tag can emphasize certain words.

The HTML sub tag works for subscripts: H2O

The HTML sup tag works for superscripts: X2

HTML must have a "begin" tag and an "end" tag. Here is what the HTML for the examples above looks like:

<mark>emphasize certain words</mark>
H<sub>2</sub>O
X<sup>2</sup>

With the "fenced code" markup, it's not necessary to escape special characters in the HTML.

LociOiling Lv 1

The old system allowed HTML in posts, but it wasn't strict about the syntax.

You could do an ordered list with the ol and li tags, but it wasn't quite right if you didn't end each li tag:

  1. item 1
  2. item 2 </ol>

    The lack of end tags messes up the rest of the post to some extent. You'll notice this text is indented, because the previous list has not really ended.

    The correct way is to end each tag with it's corresponding end tag:
    1. item 1
    2. item 2

LociOiling Lv 1

The previous example was so messed up by the lack of end tags that the fenced code markdown wasn't working right. A separate post was needed to clear that up.

Here are the bad and good examples:

Here's the bad way:
<ol>
<li>item 1
<li>item 2
</ol>
Here's the good way:
<ol>
<li>item 1</li>
<li>item 2</li>
</ol>