mirror of
https://github.com/erusev/parsedown.git
synced 2023-08-10 21:13:06 +03:00
Merge pull request #69 from KaneCohen/master
This commit is contained in:
commit
72f4a375ef
@ -1008,7 +1008,7 @@ class Parsedown
|
||||
|
||||
case 'http':
|
||||
|
||||
if (preg_match('/^https?:[\/]{2}[^\s]+\b/i', $text, $matches))
|
||||
if (preg_match('/^https?:[\/]{2}[^\s]+\b/ui', $text, $matches))
|
||||
{
|
||||
$element_url = $matches[0];
|
||||
$element_url = str_replace('&', '&', $element_url);
|
||||
@ -1069,22 +1069,22 @@ class Parsedown
|
||||
|
||||
private static $strong_regex = array(
|
||||
'*' => '/^[*]{2}([^*]+?)[*]{2}(?![*])/s',
|
||||
'_' => '/^__([^_]+?)__(?!_)/s',
|
||||
'_' => '/^__([^_]+?)__(?!_)/us',
|
||||
);
|
||||
|
||||
private static $em_regex = array(
|
||||
'*' => '/^[*]([^*]+?)[*](?![*])/s',
|
||||
'_' => '/^_([^_]+?)[_](?![_])\b/s',
|
||||
'_' => '/^_([^_]+?)[_](?![_])\b/us',
|
||||
);
|
||||
|
||||
private static $strong_em_regex = array(
|
||||
'*' => '/^[*]{2}(.*?)[*](.+?)[*](.*?)[*]{2}/s',
|
||||
'_' => '/^__(.*?)_(.+?)_(.*?)__/s',
|
||||
'_' => '/^__(.*?)_(.+?)_(.*?)__/us',
|
||||
);
|
||||
|
||||
private static $em_strong_regex = array(
|
||||
'*' => '/^[*](.*?)[*]{2}(.+?)[*]{2}(.*?)[*]/s',
|
||||
'_' => '/^_(.*?)__(.+?)__(.*?)_/s',
|
||||
'_' => '/^_(.*?)__(.+?)__(.*?)_/us',
|
||||
);
|
||||
|
||||
private static $special_characters = array(
|
||||
@ -1102,4 +1102,4 @@ class Parsedown
|
||||
'span',
|
||||
'time',
|
||||
);
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user