Browse Source

add colon to character class for cites

pull/76/head
Your Name 2 years ago
parent
commit
858a501b1f
  1. 4
      inc/functions.php

4
inc/functions.php

@ -2086,7 +2086,7 @@ function markup(&$body, $track_cites = false, $op = false) {
$tracked_cites = array(); $tracked_cites = array();
// Cites // Cites
if (isset($board) && preg_match_all('/(^|\s)>>(\d+?)((?=[\s,.)?!])|$)/m', $body, $cites, PREG_SET_ORDER | PREG_OFFSET_CAPTURE)) { if (isset($board) && preg_match_all('/(^|\s)>>(\d+?)((?=[\s,.:)?!])|$)/m', $body, $cites, PREG_SET_ORDER | PREG_OFFSET_CAPTURE)) {
if (count($cites[0]) > $config['max_cites']) { if (count($cites[0]) > $config['max_cites']) {
error($config['error']['toomanycites']); error($config['error']['toomanycites']);
} }
@ -2133,7 +2133,7 @@ function markup(&$body, $track_cites = false, $op = false) {
} }
// Cross-board linking // Cross-board linking
if (preg_match_all('/(^|\s)>>>\/(' . $config['board_regex'] . 'f?)\/(\d+)?((?=[\s,.)?!])|$)/um', $body, $cites, PREG_SET_ORDER | PREG_OFFSET_CAPTURE)) { if (preg_match_all('/(^|\s)>>>\/(' . $config['board_regex'] . 'f?)\/(\d+)?((?=[\s,.:)?!])|$)/um', $body, $cites, PREG_SET_ORDER | PREG_OFFSET_CAPTURE)) {
if (count($cites[0]) > $config['max_cites']) { if (count($cites[0]) > $config['max_cites']) {
error($config['error']['toomanycross']); error($config['error']['toomanycross']);
} }

Loading…
Cancel
Save