The HTML to Markdown converter for PHP. See the official website
$converter = new Markdownify\Converter;
$converter->parseString('<h1>Heading</h1>');
// Returns: # Heading
Markdown Extra as defined by @michelf
$converter = new Markdownify\ConverterExtra;
$converter->parseString('<h1 id="md">Heading</h1>');
// Returns: # Heading {#md}
If you don't have composer, you have to install it.
Add or complete the composer.json file at the root of your repository, like this :
{
"require": {
"pixel418/markdownify": "2.1.*"
}
}
Markdownify can now be downloaded via composer.
- Fork the Markdownify repository
- Create a new branch for each feature or improvement
- Send a pull request from each feature branch to the v2.x branch
If you don't know much about pull request, you can read the Github article.
Markdownify is under LGPL License.
It was created by Milian Wolff.
It was converted to a Symfony Bundle by Peter Kruithof.
It was made accessible by composer without Symfony by Thomas ZILLIOX.