Loading field_hidden.admin.inc +4 −4 Changes for field_hidden.admin.inc: 4 added lines, 4 removed lines. Original line number Diff line number Diff line Loading @@ -187,16 +187,16 @@ function _field_hidden_readme2html($readme_txt, $headline_tag = 'h5') { //'', ); $s = preg_replace($ndls, $rplcs, $s); // Links may be followed by a punctuation marker, hard to detect without a callback. // And http://your-drupal-site.tld/path should become /path // Links may be followed by a punctuation marker, hard to detect without a // callback. And "http://your-drupal-site.tld/path" should become "/path". $s = preg_replace_callback( '/(https?\:\/\/)(\S+)([\x20\t\n])/', function ($ms) { $protocol = $ms[1]; $le = strlen($addr = $ms[2]); $dot = ''; if (!preg_match('/[\/a-zA-Z\d]/', $addr{$le - 1})) { $dot = $addr{$le - 1}; if (isset($addr[$le - 1]) && !preg_match('/[\/a-zA-Z\d]/', $addr[$le - 1])) { $dot = $addr[$le - 1]; $addr = substr($addr, 0, $le - 1); } if (strpos($addr, 'your-drupal-site.tld/') === 0) { Loading Loading
field_hidden.admin.inc +4 −4 Changes for field_hidden.admin.inc: 4 added lines, 4 removed lines. Original line number Diff line number Diff line Loading @@ -187,16 +187,16 @@ function _field_hidden_readme2html($readme_txt, $headline_tag = 'h5') { //'', ); $s = preg_replace($ndls, $rplcs, $s); // Links may be followed by a punctuation marker, hard to detect without a callback. // And http://your-drupal-site.tld/path should become /path // Links may be followed by a punctuation marker, hard to detect without a // callback. And "http://your-drupal-site.tld/path" should become "/path". $s = preg_replace_callback( '/(https?\:\/\/)(\S+)([\x20\t\n])/', function ($ms) { $protocol = $ms[1]; $le = strlen($addr = $ms[2]); $dot = ''; if (!preg_match('/[\/a-zA-Z\d]/', $addr{$le - 1})) { $dot = $addr{$le - 1}; if (isset($addr[$le - 1]) && !preg_match('/[\/a-zA-Z\d]/', $addr[$le - 1])) { $dot = $addr[$le - 1]; $addr = substr($addr, 0, $le - 1); } if (strpos($addr, 'your-drupal-site.tld/') === 0) { Loading