Update shortcode regular expression commentary. See #17657.
git-svn-id: https://develop.svn.wordpress.org/trunk@22401 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
67ac51fe73
commit
397efc640f
@ -295,7 +295,7 @@ function shortcode_unautop( $pee ) {
|
|||||||
. '(' // 1: The shortcode
|
. '(' // 1: The shortcode
|
||||||
. '\\[' // Opening bracket
|
. '\\[' // Opening bracket
|
||||||
. "($tagregexp)" // 2: Shortcode name
|
. "($tagregexp)" // 2: Shortcode name
|
||||||
. '(?![\\w-])' // Word boundary
|
. '(?![\\w-])' // Not followed by word character or hyphen
|
||||||
// Unroll the loop: Inside the opening shortcode tag
|
// Unroll the loop: Inside the opening shortcode tag
|
||||||
. '[^\\]\\/]*' // Not a closing bracket or forward slash
|
. '[^\\]\\/]*' // Not a closing bracket or forward slash
|
||||||
. '(?:'
|
. '(?:'
|
||||||
|
@ -182,7 +182,7 @@ function get_shortcode_regex() {
|
|||||||
'\\[' // Opening bracket
|
'\\[' // Opening bracket
|
||||||
. '(\\[?)' // 1: Optional second opening bracket for escaping shortcodes: [[tag]]
|
. '(\\[?)' // 1: Optional second opening bracket for escaping shortcodes: [[tag]]
|
||||||
. "($tagregexp)" // 2: Shortcode name
|
. "($tagregexp)" // 2: Shortcode name
|
||||||
. '(?![\\w-])' // Word boundary
|
. '(?![\\w-])' // Not followed by word character or hyphen
|
||||||
. '(' // 3: Unroll the loop: Inside the opening shortcode tag
|
. '(' // 3: Unroll the loop: Inside the opening shortcode tag
|
||||||
. '[^\\]\\/]*' // Not a closing bracket or forward slash
|
. '[^\\]\\/]*' // Not a closing bracket or forward slash
|
||||||
. '(?:'
|
. '(?:'
|
||||||
|
Loading…
Reference in New Issue
Block a user