Fix form elements in bookmark plugin

This commit is contained in:
Zach Copley 2011-04-17 15:34:50 -07:00
parent 66d56456c1
commit 5f81f4c701
4 changed files with 12 additions and 7 deletions

View File

@ -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();

View File

@ -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);

View File

@ -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');

View File

@ -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;
}