Guest User

Untitled

a guest
Jan 31st, 2019
15
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 8.11 KB | None | 0 0
  1. `18-Nov-2011`: Updated to include the [latest markdown changes.](http://www.reddit.com/r/changelog/comments/mg1j6/reddit_change_new_markdown_interpreter/)
  2.  
  3. ####Contents
  4.  
  5. >1. Basic text formatting (*Italics*, **Bold**, ~~Strikethrough~~, Super^script, `inline code`, Quoting)
  6. 2. Linking
  7. 3. Line Breaks & Paragraphs
  8. 4. Lists
  9. 5. Tables
  10. 6. Block Code
  11. 7. Headlines and Horizontals
  12.  
  13. ####1\. Basic Text Formatting
  14.  
  15.  
  16. > **Italics** are created using either a single asterisk (\*) or single underscore (\_).
  17.  
  18. >Example:
  19.  
  20. >>This is \*italic text\*, this is also \_italic text\_.
  21.  
  22. >becomes:
  23.  
  24. >>This is *italic text*, this is also _italic text_.
  25.  
  26. #
  27.  
  28. >**Bold text** is created with double asterisks (\*\*) or double underscores (\_\_).
  29.  
  30. >Example:
  31.  
  32. >>This is \*\*bold text\*\*, this is also \_\_bold text\_\_.
  33.  
  34. >becomes:
  35.  
  36. >>This is **bold text**, this is also __bold text__.
  37.  
  38. #
  39.  
  40. >**Strikethrough text** is created using a double tilde (`~~`).
  41.  
  42. >Example:
  43.  
  44. >>This is `~~`strikethrough text`~~`.
  45.  
  46. >becomes:
  47.  
  48. >>This is ~~strikethrough~~ text.
  49.  
  50. #
  51.  
  52. >**Superscript text** is created using the carot (`^`).
  53.  
  54. >Example:
  55.  
  56. >> This sentence contains super`^`script.
  57.  
  58. >becomes:
  59.  
  60. >> This sentence contains super^script.
  61.  
  62. >Note that you cannot leave space before the carot, and there is no *closing tag*.
  63.  
  64. >>Superscript can also be stacked^like^this.
  65.  
  66. #
  67.  
  68. >**inline code** (monospaced text) is created using the backtick ([grave accents](http://en.wikipedia.org/wiki/Grave_accent)) (\`).
  69.  
  70. >Example:
  71.  
  72. >> This sentence contains inline code: `` ` ``javascript:alert("hello world");`` ` ``
  73.  
  74. >becomes:
  75.  
  76. >> This sentence contains inline code: `javascript:alert("hello world");`
  77.  
  78. #
  79.  
  80. >**Quoting** is achieved by starting a line with an Angle Bracket (>)
  81.  
  82. >Example:
  83.  
  84. >>\>Here's a quote.
  85.  
  86. >>\>Another paragraph in the same quote.
  87. >>\>\>A nested quote.
  88.  
  89. >>\>Back to a single quote.
  90.  
  91. >>And finally some unquoted text.
  92.  
  93. >becomes:
  94.  
  95. >>>Here's a quote.
  96.  
  97. >>>Another paragraph in the same quote.
  98. >>>>A nested quote.
  99.  
  100. >>>Back to a single quote.
  101.  
  102. >>And finally some unquoted text.
  103.  
  104. #
  105.  
  106. >To **remove formatting** you will need to use a Backslash (\\)
  107.  
  108. >Example:
  109.  
  110. >>This sentence escapes \\\*italic text\\\* and \\\*\\\*bold text\\\*\\\*.
  111.  
  112. >becomes:
  113.  
  114. >>This sentence escapes \*italic text\* and \*\*bold text\*\*.
  115.  
  116. ####2\. Linking
  117.  
  118. >**Creating a link**
  119.  
  120. >Example:
  121.  
  122. >> \[Reddit\]\(`http://reddit.com`\)
  123.  
  124. >becomes:
  125.  
  126. >> [Reddit](http://reddit.com)
  127.  
  128. >You cannot begin a link with "www", it must begin with one of the following URL schemes:
  129.  
  130. >>* http://
  131. * https://
  132. * ftp://
  133. * mailto:
  134. * steam://
  135. * irc://
  136. * news://
  137. * mumble://
  138. * ssh://
  139.  
  140. #
  141.  
  142. >You can also provide **title text** for links:
  143.  
  144. >> \[Reddit\]\(`http://reddit.com` "what's new online!"\).
  145.  
  146. >becomes:
  147.  
  148. >> [Reddit](http://reddit.com "what's new online!") ← (*hover*!)
  149.  
  150. >Title text can be used to hide **spoilers**:
  151.  
  152. >> `[spoiler](/s"The spoiler text goes here")`
  153.  
  154. >becomes:
  155.  
  156. >> [spoiler](/s"The spoiler text goes here") ← (*hover*!)
  157.  
  158. #
  159.  
  160. >Reddit now recognises when you want to **link to a subreddit**.
  161.  
  162. >Example:
  163.  
  164. >>This is a shameless plug for \/r/BritishTV!
  165.  
  166. >becomes:
  167.  
  168. >>This is a shameless plug for /r/BritishTV!
  169.  
  170. #
  171.  
  172. >If a URL contains brackets you will need to escape these.
  173.  
  174. >Example without escaping:
  175.  
  176. >>`[Cube](http://en.wikipedia.org/wiki/Cube_(film))`
  177.  
  178. >becomes:
  179.  
  180. >>[Cube](http://en.wikipedia.org/wiki/Cube_(film)) ← (*note the surplus bracket*!)
  181.  
  182. >Example with escaping:
  183.  
  184. >>`[Cube](http://en.wikipedia.org/wiki/Cube_(film\))`
  185.  
  186. >becomes:
  187.  
  188. >>[Cube](http://en.wikipedia.org/wiki/Cube_(film\)) ← (*no surplus bracket*!)
  189.  
  190. ####3\. Line Breaks & Paragraphs
  191.  
  192. >**Line breaks** in comments are achieved by adding four spaces (*shown using* ░) to the end of the line. Simply hitting return (*shown using* ↵) will not work.
  193.  
  194. >Example:
  195.  
  196. >>First line↵
  197. >>Second line
  198.  
  199. >becomes:
  200.  
  201. >>First line Second line
  202.  
  203. >but:
  204.  
  205. >>First line░░░░↵
  206. >>Second line
  207.  
  208. >becomes:
  209.  
  210. >>First line
  211. >>Second line
  212.  
  213. #
  214.  
  215. >**Paragraphs** are formed when you hit return (*shown using* ↵) twice.
  216.  
  217. >>First Paragraph↵
  218. >>↵
  219. >>Second Paragraph
  220.  
  221. >becomes:
  222.  
  223. >>First Paragraph
  224.  
  225. >>Second Paragraph
  226.  
  227. ####4\. Lists
  228.  
  229. >To create **Unordered Lists** each item should begin with either an asterisk (\*), plus sign (\+) or minus sign (\-).
  230.  
  231. >Example:
  232.  
  233. >>\* Item 1
  234. >>\+ Item 2
  235. >>\- Item 3
  236.  
  237. >becomes:
  238.  
  239. >>* Item 1
  240. >>+ Item 2
  241. >>- Item 3
  242.  
  243. #
  244.  
  245. >**Ordered Lists** are created with a number and period. It doesn't matter which number you start with, as markdown will always start with 1.
  246.  
  247. >Example:
  248.  
  249. >>3\. Item 1
  250. >>2\. Item 2
  251. >>1\. Item 3
  252.  
  253. >becomes:
  254.  
  255. >>3. Item 1
  256. >>2. Item 2
  257. >>1. Item 3
  258.  
  259. #
  260.  
  261. >The markup for **Nested Lists** has changed slightly:
  262.  
  263. >Example:
  264.  
  265. >>1\. This is Item 1
  266. >>2\.
  267. >>░░░░1\. This is Item 2.1
  268. >>░░░░2\. This is Item 2.2
  269. >>3\. This is Item 3
  270. >>4\. This is Item 4
  271.  
  272. >becomes:
  273.  
  274. >>1. This is Item 1
  275. >>2.
  276. >> 1. This is Item 2.1
  277. >> 2. This is Item 2.2
  278. >>3. This is Item 3
  279. >>4. This is Item 4
  280.  
  281. #
  282.  
  283. >Lists should be clear of any text in the line immediately above and below, the same as making a new paragraph:
  284.  
  285. >>This is the **wrong way to make a list**
  286. >>1. lorem
  287. >>2. ispum
  288. >>reddit doesn't realize it should listify...
  289.  
  290. >becomes:
  291.  
  292. >>This is the **wrong way to make a list**
  293. >>1. lorem
  294. >>2. ispum
  295. >>reddit doesn't realize it should listify...
  296.  
  297. >Place lists in their own paragraph:
  298.  
  299. >>This is the **correct way to make a list**
  300.  
  301. >>1. lorem
  302. >>2. ispum
  303.  
  304. >>reddit realizes it should listify!
  305.  
  306. >**Paragraphs in Lists** and **Nested lists using a combination of ordered and unordered lists**, are no longer supported.
  307.  
  308. ####5\. Tables
  309.  
  310. >**Tables** are created using pipes (|):
  311.  
  312. >Example
  313.  
  314. >>
  315. [](ftp://grrr.net)Left align | Center align | Right align
  316. [](ftp://grrr.net):--|:--:|--:
  317. This | This | This
  318. column | column | column
  319. will | will | will
  320. be | be | be
  321. left | center | right
  322. aligned | aligned | aligned
  323.  
  324. >becomes:
  325.  
  326. >>
  327. Left align | Center align | Right align
  328. :--|:--:|--:
  329. This | This | This
  330. column | column | column
  331. will | will | will
  332. be | be | be
  333. left | center | right
  334. aligned | aligned | aligned
  335.  
  336. >Note that by default the first row is always **bolded**.
  337.  
  338. >**Column Alignment** is determined by the second row.
  339.  
  340. >>Use "**:--:**" for centre aligned text, "**--:**" for right, and "**:--**" for left.
  341.  
  342. > You can also leave the top row empty, as long as you have the correct amount of pipes:
  343.  
  344. >>
  345. [](ftp://grr.net)||
  346. [](ftp://grrr.net):--|:--:|--:
  347. the|top|row
  348. is|now|empty
  349.  
  350. >becomes
  351.  
  352. >>
  353. | |
  354. :--|:--:|--:
  355. the|top|row
  356. is|now|empty
  357.  
  358. ####6\. Block code
  359.  
  360. >Displaying **block code**, without formatting and in monospaced font, is as simple as starting the line with four spaces (*shown using* ░).
  361.  
  362. >Example:
  363.  
  364. >>░░░░line of code
  365. >>░░░░░░░░line of code
  366. >>░░░░░░░░░░░░line of code
  367. >>░░░░░░░░line of code
  368. >>░░░░line of code
  369.  
  370. >becomes:
  371.  
  372. >>`    line of code`
  373. >>`        line of code`
  374. >>`            line of code`
  375. >>`        line of code`
  376. >>`    line of code`
  377.  
  378. ####7\. Headlines & Horizonal Rules
  379.  
  380. >**Headline text** can be created by using a number of hashes (#) corresponding to the tag you want. Headline tags will format all text until it encounters a Line Break or new Paragraph.
  381.  
  382. >>\# Headline 1
  383. >>\#\# Headline 2
  384. >>\#\#\# Headline 3
  385.  
  386. >becomes:
  387.  
  388. >>#Headline 1
  389. >>##Headline 2
  390. >>###Headline 3
  391.  
  392. >`NOTE`: Markdown supports up to six headline tags, but only the first three have default formatting.
  393.  
  394. #
  395.  
  396. >To create a **Horizontal Rule**, simply add three asterisks (\*) to an empty line.
  397.  
  398. >>\*\*\*
  399.  
  400. >becomes:
  401.  
  402. >>***
Add Comment
Please, Sign In to add comment