pluf2

pluf2 Commit Details


Date:2012-06-05 14:05:01 (12 years 6 months ago)
Author:Thomas Keller
Branch:master
Commit:8b4b7ef3a4d286d41e24a35ac7d4c9f47a85373c
Parents: 012bd110caafcb759ec0eff9cf572d9be753244c
Message:Bump Markdown (Extra) to 1.0.1o (1.2.5) which - amongst other things - fixes a problem with newer PHP 5.3 versions (issue 807).

Changes:

File differences

src/Pluf/Text/MarkDown.php
33
44
55
6
6
77
88
99
......
1212
1313
1414
15
16
15
16
1717
1818
1919
......
6868
6969
7070
71
7271
7372
7473
......
811810
812811
813812
814
813
815814
816815
817816
......
872871
873872
874873
875
874
876875
877876
878877
......
10021001
10031002
10041003
1005
1004
10061005
10071006
10081007
10091008
1010
1009
10111010
10121011
10131012
10141013
1015
1014
10161015
10171016
10181017
......
17461745
17471746
17481747
1749
1748
17501749
17511750
17521751
......
18081807
18091808
18101809
1811
1812
1813
1814
1815
1816
1817
1818
18191810
18201811
1821
1812
18221813
18231814
1824
1815
18251816
18261817
18271818
......
18341825
18351826
18361827
1828
1829
1830
1831
1832
1833
1834
1835
18371836
18381837
18391838
......
24492448
24502449
24512450
2452
2451
24532452
24542453
24552454
24562455
2457
2456
24582457
24592458
24602459
24612460
2462
2461
24632462
24642463
24652464
# Markdown Extra - A text-to-HTML conversion tool for web writers
#
# PHP Markdown & Extra
# Copyright (c) 2004-2009 Michel Fortin
# Copyright (c) 2004-2012 Michel Fortin
# <http://michelf.com/projects/php-markdown/>
#
# Original Markdown
#
define( 'MARKDOWN_VERSION', "1.0.1n" ); # Sat 10 Oct 2009
define( 'MARKDOWNEXTRA_VERSION', "1.2.4" ); # Sat 10 Oct 2009
define( 'MARKDOWN_VERSION', "1.0.1o" ); # Sun 8 Jan 2012
define( 'MARKDOWNEXTRA_VERSION', "1.2.5" ); # Sun 8 Jan 2012
#
return Markdown($text);
}
#
# Markdown Parser Class
#
# Re-usable patterns to match list item bullets and number markers:
$marker_ul_re = '[*+-]';
$marker_ol_re = '\d+[.]';
$marker_ol_re = '\d+[\.]';
$marker_any_re = "(?:$marker_ul_re|$marker_ol_re)";
$markers_relist = array(
function _doLists_callback($matches) {
# Re-usable patterns to match list item bullets and number markers:
$marker_ul_re = '[*+-]';
$marker_ol_re = '\d+[.]';
$marker_ol_re = '\d+[\.]';
$marker_any_re = "(?:$marker_ul_re|$marker_ol_re)";
$list = $matches[1];
var $em_relist = array(
'' => '(?:(?<!\*)\*(?!\*)|(?<!_)_(?!_))(?=\S|$)(?![.,:;]\s)',
'' => '(?:(?<!\*)\*(?!\*)|(?<!_)_(?!_))(?=\S|$)(?![\.,:;]\s)',
'*' => '(?<=\S|^)(?<!\*)\*(?!\*)',
'_' => '(?<=\S|^)(?<!_)_(?!_)',
);
var $strong_relist = array(
'' => '(?:(?<!\*)\*\*(?!\*)|(?<!_)__(?!_))(?=\S|$)(?![.,:;]\s)',
'' => '(?:(?<!\*)\*\*(?!\*)|(?<!_)__(?!_))(?=\S|$)(?![\.,:;]\s)',
'**' => '(?<=\S|^)(?<!\*)\*\*(?!\*)',
'__' => '(?<=\S|^)(?<!_)__(?!_)',
);
var $em_strong_relist = array(
'' => '(?:(?<!\*)\*\*\*(?!\*)|(?<!_)___(?!_))(?=\S|$)(?![.,:;]\s)',
'' => '(?:(?<!\*)\*\*\*(?!\*)|(?<!_)___(?!_))(?=\S|$)(?![\.,:;]\s)',
'***' => '(?<=\S|^)(?<!\*)\*\*\*(?!\*)',
'___' => '(?<=\S|^)(?<!_)___(?!_)',
);
|
# Fenced code block marker
(?> ^ | \n )
[ ]{'.($indent).'}~~~+[ ]*\n
[ ]{0,'.($indent).'}~~~+[ ]*\n
' : '' ). ' # End (if not is span).
)
}xs';
}
}
#
# Check for: Indented code block.
#
else if ($tag{0} == "\n" || $tag{0} == " ") {
# Indented code block: pass it unchanged, will be handled
# later.
$parsed .= $tag;
}
#
# Check for: Fenced code block marker.
#
else if ($tag{0} == "~") {
else if (preg_match('{^\n?[ ]{0,'.($indent+3).'}~}', $tag)) {
# Fenced code block marker: find matching end marker.
$tag_re = preg_quote(trim($tag));
if (preg_match('{^(?>.*\n)+?'.$tag_re.' *\n}', $text,
if (preg_match('{^(?>.*\n)+?[ ]{0,'.($indent).'}'.$tag_re.'[ ]*\n}', $text,
$matches))
{
# End marker found: pass text unchanged until marker.
}
}
#
# Check for: Indented code block.
#
else if ($tag{0} == "\n" || $tag{0} == " ") {
# Indented code block: pass it unchanged, will be handled
# later.
$parsed .= $tag;
}
#
# Check for: Opening Block level tag or
# Opening Context Block tag (like ins and del)
# used as a block tag (tag is alone on it's line).
# work in the middle of a word.
#
var $em_relist = array(
'' => '(?:(?<!\*)\*(?!\*)|(?<![a-zA-Z0-9_])_(?!_))(?=\S|$)(?![.,:;]\s)',
'' => '(?:(?<!\*)\*(?!\*)|(?<![a-zA-Z0-9_])_(?!_))(?=\S|$)(?![\.,:;]\s)',
'*' => '(?<=\S|^)(?<!\*)\*(?!\*)',
'_' => '(?<=\S|^)(?<!_)_(?![a-zA-Z0-9_])',
);
var $strong_relist = array(
'' => '(?:(?<!\*)\*\*(?!\*)|(?<![a-zA-Z0-9_])__(?!_))(?=\S|$)(?![.,:;]\s)',
'' => '(?:(?<!\*)\*\*(?!\*)|(?<![a-zA-Z0-9_])__(?!_))(?=\S|$)(?![\.,:;]\s)',
'**' => '(?<=\S|^)(?<!\*)\*\*(?!\*)',
'__' => '(?<=\S|^)(?<!_)__(?![a-zA-Z0-9_])',
);
var $em_strong_relist = array(
'' => '(?:(?<!\*)\*\*\*(?!\*)|(?<![a-zA-Z0-9_])___(?!_))(?=\S|$)(?![.,:;]\s)',
'' => '(?:(?<!\*)\*\*\*(?!\*)|(?<![a-zA-Z0-9_])___(?!_))(?=\S|$)(?![\.,:;]\s)',
'***' => '(?<=\S|^)(?<!\*)\*\*\*(?!\*)',
'___' => '(?<=\S|^)(?<!_)___(?![a-zA-Z0-9_])',
);

Archive Download the corresponding diff file

Branches

Number of commits:
Page rendered in 0.05899s using 14 queries.