[wp-trac] Re: [WordPress Trac] #6969: Don't apply wptexturize() to the insides of shortcode tags

WordPress Trac wp-trac at lists.automattic.com
Fri Jan 23 00:06:58 GMT 2009


#6969: Don't apply wptexturize() to the insides of shortcode tags
-------------------------------------+--------------------------------------
 Reporter:  Viper007Bond             |        Owner:  tellyworth
     Type:  enhancement              |       Status:  new       
 Priority:  normal                   |    Milestone:  2.8       
Component:  General                  |      Version:  2.5.1     
 Severity:  normal                   |   Resolution:            
 Keywords:  has-patch needs-testing  |  
-------------------------------------+--------------------------------------
Comment (by JakaJancar):

 Right, sorry my bad. I'm still a bit puzzled by this change though.

 - $textarr = preg_split('/(<.*>|\[.*\])/Us', $text, -1,
 PREG_SPLIT_DELIM_CAPTURE);
 + $textarr = preg_split('/([<\[].*[>\]]|\[.*\])/Us', $text, -1,
 PREG_SPLIT_DELIM_CAPTURE);

 So instead of <> tags and [] tags, now also <] and [> tags are possible?
 What's the point of that? And why is the second part of the new regexp
 even needed ( \[.*\] ), shouldn't these tags all be matched by the first
 part anyways ( [<\[].*[>\]] ).

 I'm not looking at the bigger picture here, so if I'm not making any sense
 at all, just ignore me =)

-- 
Ticket URL: <http://trac.wordpress.org/ticket/6969#comment:7>
WordPress Trac <http://trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list