Release Date: 2021-07-19
- Deprecate
parse()
andparse_file()
methods in favor oftransform()
andtransform_file()
, respectively. The deprecated methods will remain in the API for backwards compatibility for the time being, but you should update your callers ASAP to avoid any potential service interruptions going forward as future updates are released.
Release Date: 2020-05-22
- Added the ability to programmatically configure the Markdown instance, overriding (recursively) any settings defined in the config file.
Release Date: 2018-11-21
- Added
fn_backlink_label
configuration variable to put some text in thearia-label
attribute. - Occurrences of "
^^
" infn_backlink_html
,fn_backlink_class
,fn_backlink_title
, andfn_backlink_label
will be replaced by the corresponding footnote number in the HTML output. Occurrences of "%%
" will be replaced by a number for the reference (footnotes can have multiple references).
Release Date: 2018-05-29
- Cleanup code and delete unused variables.
Release Date: 2018-04-01
-
Added configuration variable
omit_footnotes
. Whentrue
footnotes are not appended at the end of the generated HTML, and thefootnotes_assembled
variable will contain the HTML for the footnote list, allowing footnotes to be moved somewhere else on the page.NOTE: when placing the content of
footnotes_assembled
on the page, consider adding the attributerole="doc-endnotes"
to the<div>
or<section>
that will enclose the list of footnotes so they are reachable to accessibility tools the same way they would be with the default HTML output.
Release Date: 2018-01-20
- HTML output for Markdown Extra footnotes now include
role
attributes with values from WAI-ARIA to make them more accessible.
Release Date: 2017-10-21
- Avoid unnecessary reentrancy in
doItalicsAndBold
. - Reset the state for regular emphasis when unwinding in
toItalicsAndBold
.
Release Date: 2017-07-08
Added the hashtag_protection
configuration variable. When true
, prevents
ATX-style headers with no space after the initial hash from being interpreted as
headers. This way those precious hash-tags can be preserved.
Release Date: 2016-10-30
- Fixed a Markdown Extra issue where two-space-at-end-of-line hard breaks
wouldn't work inside of HTML block elements such as
<p markdown="1">
where the element expects only span-level content.
Release Date: 2016-09-05
- PHP Markdown settings
can now be specified in the
config/markdown.php
config file.
Release Date: 2016-09-04
- Added a
hard_wrap
configuration variable to make all newline characters in the text become<br>
tags in the HTML output. By default, according to the standard Markdown syntax these newlines are ignored unless they a preceded by two spaces. Thanks to Jonathan Cohlmeyer for the implementation.
Release Date: 2016-03-26
- Allow custom content function for code span. Just like the option
$code_block_content_func
, but now for code-span. Can be used to prevent the defaulthtmlspecialchars
or do some kind of other logic to convert the code to html.
Release Date: 2015-12-29
- Fixed an issue in MarkdownExtra where long header lines followed by a special attribute block would hit the backtrack limit an cause an empty string to be returned.
- Run PHP CS Fixer rules (PSR2 + Symfony).
Release Date: 2015-10-17
- The curled arrow character for the backlink in footnotes is now followed by a
Unicode variant selector to prevent it from being displayed in emoji form on
iOS. Note that in older browsers the variant selector is often interpreted as
a separate character, making it visible after the arrow. So there is now a
also a
fn_backlink_html
configuration variable that can be used to set the link text to something else.
Release Date: 2015-08-08
- You can now set a class name for the code block's language before the special attribute block. Previously, this class name was only allowed in the absence of the special attribute block.
- Added a
code_block_content_func
configuration variable which takes a function that will convert the content of the code block to HTML. This is most useful for syntax highlighting. For fenced code blocks in Markdown Extra, the function has access to the language class name (the one outside of the special attribute block). Credits to Mario Konrad for providing the implementation. - Convert private members and methods to protected to allow inheritance.
- Update code header.
Release Date: 2015-06-13
- Reduce nesting in parse functions.
- Minor whitespace adjustments.
Release Date: 2015-03-29
Merge PHP Markdown v1.5.0 Changes
- Added the ability start ordered lists with a number different from 1 and and
have that reflected in the HTML output. This can be enabled with the
enhanced_ordered_lists
configuration variable for the Markdown parser; it is enabled by default for Markdown Extra. Credits to Matt Gorle for providing the implementation. - Added the ability to insert custom HTML attributes with simple values everywhere an extra attribute block is allowed (links, images, headers). The value must be unquoted, cannot contains spaces and is limited to alphanumeric ASCII characters. Credits to Peter Droogmans for providing the implementation.
- Added a
header_id_func
configuration variable which takes a function that can generate anid
attribute value from the header text. Credits to Evert Pot for providing the implementation. - Added a
url_filter_func
configuration variable which takes a function that can rewrite any link or image URL to something different.
Release Date: 2015-01-09
- Remove passing instance references to callbacks.
Release Date: 2014-12-30
- Bake in PHP Markdown Extra.
Release Date: 2014-12-29
- Add Doc Blocks comments.
Release Date: 2014-12-27
- Whitespace clean-up.
- Remove legacy class constructor.
Release Date: 2012-10-20
- Rename
parse_markdown()
andparse_markdown_file()
toparse()
andparse_file()
. - Ensure file is readable in
parse_file()
. - Whitespace clean-up.
Release Date: 2012-10-14
- Rename
Markdown_Parser
class toMarkdown
. - Remove WordPress interface.
- Remove Smarty interface.
- Remove Textile interface.
- Remove BBLOG interface.
- Use HTML5 empty tags.
- Remove constant declarations.
- Move all properties to top of file, before ctor.
- Add CodeIgniter debug message to ctor.