From 5f81f4c7013486c11305d4a38f103b8cd9caf140 Mon Sep 17 00:00:00 2001 From: Zach Copley Date: Sun, 17 Apr 2011 15:34:50 -0700 Subject: [PATCH] Fix form elements in bookmark plugin --- plugins/Bookmark/bookmarkform.php | 3 +++ plugins/Bookmark/bookmarkforurl.php | 3 +-- plugins/Bookmark/initialbookmarkform.php | 5 ++++- plugins/Bookmark/newbookmark.php | 8 ++++---- 4 files changed, 12 insertions(+), 7 deletions(-) diff --git a/plugins/Bookmark/bookmarkform.php b/plugins/Bookmark/bookmarkform.php index 5f355cdb2f..802bbe6c9c 100644 --- a/plugins/Bookmark/bookmarkform.php +++ b/plugins/Bookmark/bookmarkform.php @@ -120,6 +120,7 @@ class BookmarkForm extends Form // TRANS: Field label on form for adding a new bookmark. _m('LABEL','URL'), $this->_url, + null, 'url'); $this->unli(); @@ -138,6 +139,7 @@ class BookmarkForm extends Form // TRANS: Field label on form for adding a new bookmark. _m('LABEL','Title'), $this->_title, + null, 'title'); $this->unli(); @@ -146,6 +148,7 @@ class BookmarkForm extends Form // TRANS: Field label on form for adding a new bookmark. _m('LABEL','Notes'), $this->_description, + null, 'description'); $this->unli(); diff --git a/plugins/Bookmark/bookmarkforurl.php b/plugins/Bookmark/bookmarkforurl.php index 0c7a94b937..d3a1a2c76f 100644 --- a/plugins/Bookmark/bookmarkforurl.php +++ b/plugins/Bookmark/bookmarkforurl.php @@ -67,8 +67,7 @@ class BookmarkforurlAction extends Action } $this->checkSessionToken(); - - $this->url = $this->trimmed('initial-bookmark-url'); + $this->url = $this->trimmed('url'); if (empty($this->url)) { throw new ClientException(_('URL is required.'), 400); diff --git a/plugins/Bookmark/initialbookmarkform.php b/plugins/Bookmark/initialbookmarkform.php index c49bd67432..70a2657783 100644 --- a/plugins/Bookmark/initialbookmarkform.php +++ b/plugins/Bookmark/initialbookmarkform.php @@ -75,7 +75,10 @@ class InitialBookmarkForm extends Form $this->li(); $this->out->input('initial-bookmark-url', // TRANS: Field label on form for adding a new bookmark. - _m('LABEL','URL')); + _m('LABEL','URL'), + null, + null, + 'url'); $this->unli(); $this->out->elementEnd('ul'); diff --git a/plugins/Bookmark/newbookmark.php b/plugins/Bookmark/newbookmark.php index 8c60fc1596..92e9bc81c5 100644 --- a/plugins/Bookmark/newbookmark.php +++ b/plugins/Bookmark/newbookmark.php @@ -87,10 +87,10 @@ class NewbookmarkAction extends Action $this->checkSessionToken(); } - $this->title = $this->trimmed('bookmark-title'); - $this->url = $this->trimmed('bookmark-url'); - $this->tags = $this->trimmed('bookmark-tags'); - $this->description = $this->trimmed('bookmark-description'); + $this->title = $this->trimmed('title'); + $this->url = $this->trimmed('url'); + $this->tags = $this->trimmed('tags'); + $this->description = $this->trimmed('description'); return true; } -- 2.39.5