1
0
mirror of https://github.com/erusev/parsedown.git synced 2023-08-10 21:13:06 +03:00
This commit is contained in:
Emanuil Rusev
2015-01-15 02:24:39 +02:00
parent 09e1184d9f
commit 9ed72ccd09
5 changed files with 14 additions and 5 deletions

View File

@ -1298,7 +1298,7 @@ class Parsedown
return;
}
if (preg_match('/^\([ ]*([^ ]+?)(?:[ ]+(".+?"|\'.+?\'))?[ ]*\)/', $remainder, $matches))
if (preg_match('/^[(]((?:[^ (]|[(][^ )]+[)])+)(?:[ ]+("[^"]+"|\'[^\']+\'))?[)]/', $remainder, $matches))
{
$Element['attributes']['href'] = $matches[1];