[wp-trac] [WordPress Trac] #14691: Allow commas in tag names

WordPress Trac wp-trac at lists.automattic.com
Wed Aug 25 09:51:09 UTC 2010


#14691: Allow commas in tag names
-------------------------+--------------------------------------------------
 Reporter:  mdawaffe     |       Owner:                         
     Type:  enhancement  |      Status:  new                    
 Priority:  normal       |   Milestone:  Awaiting Review        
Component:  Taxonomy     |     Version:  3.0.1                  
 Severity:  normal       |    Keywords:  has-patch needs-testing
-------------------------+--------------------------------------------------
 Adding tags to posts via the web interface involves a lot of what boils
 down to
 {{{
 explode( ',', join( ',', array( $tag_name, ... ) ) );
 }}}
 both in PHP and JS.

 We settled on commas so we could have tags with spaces in them (see
 #10320, for example).

 It'd be nice if tags (and other taxonomies) could have commas in them,
 though.  Example use case: normalized locations ("Portland, OR").
 Admittedly, commas in tag names is an edge case.

 The attached treats tag inputs as "real" CSV strings instead of just
 exploding by commas.

 That way, you can enter:
 {{{
 hello, "hello, world"
 }}}
 in the tags input field and the following tags would be added to the post.
  * hello
  * hello, world

 This addresses commas in tag names but makes entering double quotes in tag
 names more annoying.  If you wanted a tag named {{{double"quote}}}, you'd
 have to enter the following.
 {{{
 "double""quote"
 }}}

 This may also help with #7897.

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/14691>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list