summaryrefslogtreecommitdiff
path: root/views
diff options
context:
space:
mode:
authorAaron Parecki <aaron@parecki.com>2018-05-27 08:48:37 -0700
committerAaron Parecki <aaron@parecki.com>2018-05-27 08:48:37 -0700
commit1c3b6f50df9c1106bd44dbb201f265f144c1fb3c (patch)
treefc3a6c917a29e5b6d91c23185a0475f4b701a067 /views
parent4a0cb5a5b3f3a8e1e4dfd8665c8982a48e92f90a (diff)
split tags using tokenfield instead of comma-separated
this allows tag values to contain spaces, which is up to your own micropub server to handle appropriately. closes #95 and replaces #96
Diffstat (limited to 'views')
-rw-r--r--views/event.php2
-rw-r--r--views/new-bookmark.php2
-rw-r--r--views/new-itinerary.php2
-rw-r--r--views/new-post.php2
4 files changed, 4 insertions, 4 deletions
diff --git a/views/event.php b/views/event.php
index a71ce79..c50e1d4 100644
--- a/views/event.php
+++ b/views/event.php
@@ -73,7 +73,7 @@
name: $("#event_name").val(),
start: event_start,
location: $("#event_location").val(),
- category: csv_to_array($("#note_category").val())
+ category: tokenfieldToArray("#note_category")
};
if(event_end) {
diff --git a/views/new-bookmark.php b/views/new-bookmark.php
index 068422f..0cc19d7 100644
--- a/views/new-bookmark.php
+++ b/views/new-bookmark.php
@@ -89,7 +89,7 @@ $(function(){
'bookmark-of': $("#note_bookmark").val(),
name: $("#note_name").val(),
content: $("#note_content").val(),
- category: csv_to_array($("#note_category").val()),
+ category: tokenfieldToArray("#note_category"),
'<?= $this->user->micropub_syndicate_field ?>': syndications
}, function(response){
if(response.location != false) {
diff --git a/views/new-itinerary.php b/views/new-itinerary.php
index e7eab1c..f8c9b02 100644
--- a/views/new-itinerary.php
+++ b/views/new-itinerary.php
@@ -180,7 +180,7 @@ $(function(){
});
});
- var category = csv_to_array($("#note_category").val());
+ var category = tokenfieldToArray("#note_category");
properties = {
itinerary: itinerary
diff --git a/views/new-post.php b/views/new-post.php
index 030ca61..9779c1e 100644
--- a/views/new-post.php
+++ b/views/new-post.php
@@ -689,7 +689,7 @@ $(function(){
syndications.push($(btn).data('syndicate-to'));
});
- var category = csv_to_array($("#note_category").val());
+ var category = tokenfieldToArray("#note_category");
var formData = new FormData();
var entry = {};