4

With the following question, Interesting Windows 7 boot Issue involving RAID and an SSD, I'm not able to remove the quote block in which the code block is embedded. Without making it a quote, the code block won't show as illustrated here: https://superuser.com/posts/179135/revisions (Revisions 3 and 4)

What am I doing wrong here?

1 Answer 1

3

It's a gotcha when dealing with lists and code.

List items may consist of multiple paragraphs. Each subsequent paragraph in a list item must be indented by either 4 spaces or one tab:

Since code is also indented by 4 spaces/one tab it thinks it's a subsequent paragraph.

To put a code block within a list item, the code block needs to be indented twice — 8 spaces or two tabs:

Markdown Syntax: List

Have edited the fix into the question.

2
  • There's still one thing... it seems as if the code block now has a double indent, in the source as in the normal view... there must be a way to fix this...
    – Pylsa
    Commented Aug 24, 2010 at 9:19
  • @BloodPhilla: As far as Markdown is concerned it's part of the list item. To stop that you'd need to put a block level element of some kind between the list and code block. Then you can use the code block as you would normally. What I did was just take the last bit of the last point and moved it into a paragraph on it's own to separate the list and the code. Which one do you prefer?
    – Chealion
    Commented Aug 24, 2010 at 14:42

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .