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

WordPress Trac noreply at wordpress.org
Thu Oct 10 22:39:16 UTC 2013


#14691: Allow commas in tag names
-------------------------------------------------+-------------------------
 Reporter:  mdawaffe                             |       Owner:
     Type:  enhancement                          |      Status:  new
 Priority:  normal                               |   Milestone:  Future
Component:  Taxonomy                             |  Release
 Severity:  normal                               |     Version:  3.0.1
 Keywords:  has-patch needs-testing needs-unit-  |  Resolution:
  tests                                          |
-------------------------------------------------+-------------------------

Comment (by joehoyle):

 So, I took a bash at getting this working, which included updating some of
 the tags JavaScript as it's frankly rather convoluted right now. Rather
 than having to rely on a storing the current tags in the `<textarea>`
 which makes parsing difficult when removing tags etc, it just parses the
 `<textarea>` once on page load, and then uses a `jQuery` data object on
 the `tagsdiv`. This means we don't need to do any `flushTags` or cleaning
 because the tags are stored in `<input type="hidden" />` and also on in
 the `tagsdiv` jQuery object.

 Here is a quick demo of me using it:

 [[Image(https://f.cloud.github.com/assets/161683/1310981/4f9e5f90-31fc-
 11e3-83c0-bd95179dfea4.gif)]]

 I also had to patch the jQuery Suggest library as it currently doesn't
 support selecting options that contain the delimiter. I think this is a
 "bug" with the current library so don't see any issue with the fix I
 propose.

 This is still compatible with JS disabled.

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


More information about the wp-trac mailing list