Expanded perl version of John Gruber's original Markdown --- No longer under active development since MMD 3 MultiMarkdown

How to style an individual list in markdown for HTML output

I'm trying to style an individual list in an Markdown document which will get converted into HTML. I cannot style the li tag via CSS, because than all lists are styled and I cannot use a div around the special list, because then multimarkdown will not convert the Markdown inside the div. So I tried span instead.

Here the sample Markdown document:

A normal list:

* List-item-one
* List-item-two

The special-styled list:

<span class="linelist">

* List-item-alpha
* List-item-beta


I convert this via multimarkdown to HTML. The relevant section showing the special list looks like this:

<p><span class="linelist"></p>



So far so good, but when I use a CSS with the following linelist class

.linelist {
    display: inline;
    color: red;

the special list is in the browser still rendered without colour or inline attribute.

How can I apply or "inject" the linelist class to the list items without adding the class to the ul or li tag (because Markdown generates the list).

Update: The markdown converter which gets used is a variant of the Discount library. Would be nice if there is a pure CSS solution independent of the converter.

Source: (StackOverflow)

Creating a cover page with MultiMarkdown

I'm playing around with Markdown and Marked for writing documentation for university projects, but need to be able to print these documents with a cover page.

I'm wondering if there's any options out there for generating HTML or PDF from MultiMarkdown that takes the meta information (title, author, date, etc.) and includes it as a cover page. HTML would be ideal as I could then provide whatever styling I needed myself.

Is something like this possible or am I using the wrong tool for the job? Suggestions for any other super lightweight markup languages for writing academic documents would be great as well. Anything where I can style the output with simple CSS is preferred!

Source: (StackOverflow)

Multimarkdown well configured header data

Hi I'm trying to get the top of my multimarkdown file to look like:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd"> 
<html xmlns="http://www.w3.org/1999/xhtml">
    <head><title>Test of markdown</title>
        <meta http-equiv="content-type" content="text/html; charset=UTF-8" />
        <link rel="stylesheet" type="text/css" rel='nofollow' href="../main.css" />

I know how to add the following metatags:

Title: Test of markdown
CSS: ../main.css
Quotes language: english

which gives me :

<!DOCTYPE html>
        <meta charset="utf-8"/>
        <title>Test of markdown</title>
        <link type="text/css" rel="stylesheet" rel='nofollow' href="../main.css"/>

But I'm not sure how to add the rest. Would appreciate any help. Thanks

Source: (StackOverflow)

how to create a sql comment in multimarkdown?

It appears that multimarkdown has a feature which converts two consecutive hyphens -- into an emdash .

For example, in the Byword editor, when you type those two hyphens it automatically converts to an emdash.

This is fine, and very useful for those writing longform text. However, it gets in the way when trying to document a SQL statement which includes a comment.

Is there a way to escape this behavior so that it shows up correctly within a fenced code block?

Source: (StackOverflow)

Can I use custom css / jquery plugins / html in my markdown file

I am trying markdown for creating notes and I feel limited in terms to style my notes and making it rich in style. for e.g. I would like to add warning/info style blocks using bootstrap css. How can I achieve this? I tried to add html in my markdown file as below:

<html lang="en">
    <meta charset="UTF-8">
    <link rel="stylesheet" rel='nofollow' href="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/3.3.1/js/bootstrap.min.js">
#Class 1

<button type="submit" class="btn btn-info">Submit</button>

But this doesn't seem to work. I am looking to do the following in my markdown file:

  1. Add bootstrap style warning/comments/suggestion blocks
  2. Placing images in a jQuery slider
  3. Placing a youtube or vimeo video in my markdown with features to control the playback controls
  4. Placing a soundcloud audio clip using a jQuery plugin
  5. Placing two or more images side by side with tooltip text

Please suggest if markdown can handle the above. I looked for Markdown,MultiMarkdown, Jekyll, but unable to find the answer to my questions. How markdown works? Can I mix html and markdown together?

Update: Tried multimarkdown syntax to include the css but that doesn't seem to work. Below is what I tried

CSS: https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/3.3.1/js/bootstrap.min.js

<style type="text/css"> 
 @import url("https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/3.3.1/js/bootstrap.min.js");
<button type="submit" class="btn btn-default">Submit</button>

Source: (StackOverflow)

How to handle special characters in markdown?

I am just discovering Markdown and MultiMarkdown and I am loving it so far. However, special characters are not properly escaped when exporting to HTML and come out as garbage in the browser.


How does Markdown handle special characters?

For example, German is full of ä, ö, ü and ß.

is converted to

<h1 id="howdoesmarkdownhandlespecialcharacters">How does Markdown handle special characters?</h1>

<p>For example, German is full of ä, ö, ü and ß.</p>

Since I have to write in German a lot, entering the escape sequences by hand is not an option. How can I get HTML output with properly escaped special characters?

Source: (StackOverflow)

sublime text 2 build system for multimarkdown under windows 7

To process a .md file in multimarkdown, I've written a build system file:

"working_dir" : "${file_path}",
"cmd": ["C:\\Program Files\\MultiMarkdown\\multimarkdown.exe", "-b", "$file"],
"cmd": "${file/\\.md/\\.html/}"

While the .html file opens in my browser correctly (if it exists), MultiMarkdown isn't called - since the .html file isn't generated by CTRL+B/F7.

However, in cmd this works:

multimarkdown -b test.md 

I guess my PATH variable is fine, but Sublime can't access multimarkdown.

I've tried this as well:

"cmd": ["multimarkdown", "-b", "$file"],


"cmd": ["multimarkdown -b", "$file"],

Source: (StackOverflow)

Is there any Markdown syntax parser for JavaScript with table?

I am looking for a Markdown syntax JavaScript parser with the table feature. It seems that I cant find one so I am having the hassle of implementing this feature into existing code, but I am not being able to do so. Does anyone know a JavaScript library that parses MULTIMARKDOWN or at least a not so difficult way to implement the table feature?

By table feature I mean a syntax to be transformed in an HTML table, for example:

|= header1 |= hader2
| cell 1 | cell 2

would become


So far I have even tried mixing a Wiki parser with Markdown parser with no success.

EDIT: I need it to run on the browser not for node.js

Source: (StackOverflow)

Retrieving variables (document metadata) from a MultiMarkdown document with PHP

How can I retrieve MultiMarkdown document metadata (as defined here) using php? I was rather surprised that I couldn't find a MultiMarkdown php parser, PHP Markdown Extra doesn't do MultiMarkdown.

I'm afraid that the scripts that MultiMarkdown's comes packaged with have all the answers for somebody that would know how to define/use a custom XSLT, but sadly that's not my case.

MultiMarkdown Document Metadata goes like this:

Title: A New MultiMarkdown Document
Author: Fletcher T. Penney
John Doe
Date: July 25, 2005

I would like to use my own properties and control where they will be displayed in the output. By default, mmd2XHTML outputs the above (pre-defined) variables in tags, but I need to display them somewhere in the HTML body.


Source: (StackOverflow)

pandoc mmd_title_block appears not to load

I am new to pandoc and an attempting to use it to convert some simple mmd files to docx. These mmd files contain a mmd style title block in the following form:

Author: Author_name  
Title: Title_name  
Date: Date_name  

I prefer this style to the pandoc style title blocks, so I would like to keep them in the multimarkdown style. The pandoc documentation indicates that there is an extension that will allow me to use them, but when I attempt to use the extension it has no effect on the output. I have tried many permutations of the command to no avail, but an example looks like this:

pandoc -f markdown-pandoc_title_block+mmd_title_block -o test.docx testinput.txt

If I convert the title block to use pandoc's style, the output properly converts the title blocks to the correct format in the resulting Word file, so I know the reference file is okay. Also, when I keep the title block in pandoc's style but use the markdown-pandoc_title_block command, it properly ignores the title block, so I know the problem is not in the disabling of pandoc title blocks.

Suggestions on what I might be doing wrong?

Source: (StackOverflow)

Best markup format for future-proofing large text chunks?

I have a number of records (=< 100) that contain sizeable chunks of text that require marking up (semantically: lists, headings, tables, links, quotations, etc...) before storing in a re-usable file format.

When stored, it is likely to remain more or less unchanged for as many years into the future as possible.

It contains some non-ascii, so UTF-8 is required. I started using HTML, then considered Markdown... but would like to know what people think is the most future-proof markup format for long-term storage? The content is initially for a (mostly static) website, but may be used as content for other outputs.

Finally, opinions on the choice of storage for long-term use - database, separate documents...? Changes to records will be infrequent and edited by only 1-3 people, and read access should increase over time.


I've finally chosen the common features (e.g. for tables) between MultiMarkdown, PHP Markdown Extra and Kramdown as the text format (Markdown omits too many HTML tags), and am converting the resulting files to html with Kramdown. Now I'm trying out iOS Markdown editors that can handle an extended Markdown and sync via Dropbox to my desk/laptop.

Source: (StackOverflow)

How to get MultiMarkDown to view tables in Sublime Text 2 OSX

I am trying to avoid using inline HTML to get tables working in my MD file. I have Markdown Preview and Table Editor installed via the package installer, and multimarkdown installed via homebrew, but I can't get the following text to display as a table:

| Left align adsf  | Right align | Center align |
| :--------------- | ----------: | :----------: |
| This             |        This |     This     |
| column           |      column |    column    |
| will             |        will |     will     |
| be               |          be |      be      |
| left             |       right |    center    |
| aligned          |     aligned |   aligned    |

When I "Markdown Preview" it just displays like this:

| | | Left align adsf | Right align | Center align | | --- | --- | ---------------- | ----------- | ------------ | | | | ---------------s | ----------- | ------------ | | --- | --- | :--------------- | ----------: | :----------: | | | | This | This | This | | | | column | column | column | | | | will | will | will | | | | be | be | be | | | | left | right | center | | | | aligned | aligned | aligned |

I have switched the file type to MultiMarkdown (lower right portion of ST2 screen)

I have searched, and it appears some people have a build system, or other approaches I have been unable to get going. What am I missing? If a build system is needed, how do I set up one? I am mainly interested in viewing this in HTML, but wouldn't be opposed to other ways....

Source: (StackOverflow)

Vim maths syntax highlighting

I'm trying to improve the syntax highlighting of maths in markdown documents.

Multimarkdown uses brackets \\[ .. \\] and \\( .. \\) to indicate display and inline math respectively. I want to highlight the contents of these with TeX.

Here's what I've got so far:

syntax include @tex syntax/tex.vim
syn region displaymaths matchgroup=mkdMaths start = "\\\\\[" end="\\\\\]" contains=@tex
syn region inlinemaths matchgroup=mkdMaths start = "\\\\(" end="\\\\)" contains=@tex
hi def link mkdMaths SpecialComment

The problem is that what is inside the brackets isn't picked up as maths by tex.vim because it isn't enclosed in $ .. $. Is there a way I can get around this? I think it is the texMath group in syntax/tex.vim that I want to use here.

Is there some way I can force the contents of the brackets to be interpreted as Tex maths?

Source: (StackOverflow)

Add ID or Class to Markdown-element

Is it possible to add an id or class to a (multi)markdown element?

For example a table, a paragraph or block of code?

I would like to style a table with css but non of following work:

[captionid][This is the caption, not the table id]
| First Header  | Second Header |
| ------------- | ------------- |
| Content Cell  | Content Cell  |
| Content Cell  | Content Cell  |

| First Header  | Second Header |
| ------------- | ------------- |
| Content Cell  | Content Cell  |
| Content Cell  | Content Cell  |
[captionid][This is the caption, not the table id]

| First Header  | Second Header |
| ------------- | ------------- |
| Content Cell  | Content Cell  |
| Content Cell  | Content Cell  |

<div class="special_table">

| First Header  | Second Header |
| ------------- | ------------- |
| Content Cell  | Content Cell  |
| Content Cell  | Content Cell  |


Can't find anything else online..

I dont mean github or stackoverflow flavored markdown btw.

Source: (StackOverflow)

How do I add footnotes to GitHub flavoured Markdown?

I am just trying to add footnotes in my GitHub Gist, but it doesn't work:

Some long sentence. [^footnote]

[^footnote]: Test, [Link](https://google.com).

I am following this guide and I don't think I'm doing anything wrong. Can someone point out my mistake?

Source: (StackOverflow)