Browse Source

Use Tokenfield to break up the input (fixes #95)

The csv_to_array function breaks on commas *and* spaces, but the
Tokenfield-based UI is set up so that tags may contain spaces.
Fortunately Tokenfield includes a function to break the field into an
array for you, so I just used that function instead.

(This patch has not been tested.)
pull/96/head
Benjamin Esham 7 years ago
parent
commit
960bbbbcfc
  1. 2
      views/new-post.php

2
views/new-post.php

@ -689,7 +689,7 @@ $(function(){
syndications.push($(btn).data('syndicate-to')); syndications.push($(btn).data('syndicate-to'));
}); });
var category = csv_to_array($("#note_category").val());
var category = $("#note_category").tokenfield("getTokens");
var formData = new FormData(); var formData = new FormData();
var entry = {}; var entry = {};

Loading…
Cancel
Save