Make WordPress Core

Changes between Initial Version and Version 1 of Ticket #9405, comment 16


Ignore:
Timestamp:
06/17/2015 01:37:43 PM (11 years ago)
Author:
aaroncampbell
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #9405, comment 16

    initial v1  
    77> The shortcode regexps are pretty big/slow already, making them even more complex is undesirable imho. Also, imagine the billions of times this slower regexp will run every day. Is it really worth the extra kWh of electricity for the servers so we can have slightly fancier attribute names (that few would ever use)?
    88
    9 This actually doesn't affect the main shortcode regex (the one we've struggled with keeping memory-friendly). It only affects the shortcode attributes regex, which is only ever run on the content inside the opening shortcode tag (match 3 from the shortcode regex). Since the change is one that affects only the attributes regex, and since the only change to that regex it to use `[\w-]` instead of `\w` for attribute names, I think it's a reasonable move.
     9This actually doesn't affect the main shortcode regex (the one we've struggled with keeping memory-friendly). That one actually got support for hyphens almost three years ago in #17657. It only affects the shortcode attributes regex, which is only ever run on the content inside the opening shortcode tag (match 3 from the shortcode regex). Since the change is one that affects only the attributes regex, and since the only change to that regex it to use `[\w-]` instead of `\w` for attribute names, I think it's a reasonable move.