Support » Plugin: WP-Markdown » Support for atx-style headers?

Viewing 3 replies - 1 through 3 (of 3 total)
  • I figured this out. SOrry for the confusion. Here are my findings:

    H1 does not work well, but these two formats work:

    #heading1#
    #heading

    The problem is that when editing an existing post, H1 gets translated to # Heading (note the space)—which turns into an ordered list when you save.

    H2 and below seem to work: ## h2 etc.

    So avoid H1, which is a best-practice anyway since it’s used for the post title.

    Plugin Author Stephen Harris

    (@stephenharris)

    Hi,

    H1 works fine for me. #heading1# and #heading1 does get converted to # heading1, but hashtags aren’t used for lists in markdown, and so it shouldn’t (and doesn’t, for me) render as a list.

    Have you got a minimum working example of the bug? I’ve tested with the following with no issue:

    # Header 1
    
    Pagaraph text
    
    # Header 1
    
    Paragraph text

    Hey Stephen Harris

    First, thanks for the reply!

    Second, I’ve done some testing, and I think this only happens with the P2 theme. This is because P2 does some list formatting, including using # for lists. So even without the wp-markdown plugin, P2’s list-creator turns this:

    # one
    # two
    #three

    into:

    1.  one
    2.  two
    3.  three

    With the wp-markdown plugin, this:

    # one
    # two
    # three
    
    #heading 1
    
    ## heading 2

    Turns into this on first save:

    1.  one
    2.  two
    3.  three
    
    # heading 1
    
    ## heading 2

    and on 2nd save:

    1.  one
    2.  two
    3.  three
    
    1.  heading 1
    
    ## heading 2

    I don’t think there’s much to do with this rather than gape in amazement or disable p2’s list-creator.

    Thanks again
    mickey

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Support for atx-style headers?’ is closed to new replies.