use <li>s in form data for site admin panel

This commit is contained in:
Evan Prodromou 2009-11-11 01:00:41 -05:00
parent 935410e8dc
commit b2145a6e4c

View File

@ -197,15 +197,25 @@ class SiteAdminPanelForm extends Form
function formData() function formData()
{ {
$this->out->elementStart('ul', 'form_data');
$this->li();
$this->input('name', _('Site name'), $this->input('name', _('Site name'),
_('The name of your site, like "Yourcompany Microblog"')); _('The name of your site, like "Yourcompany Microblog"'));
$this->unli();
$this->li();
$this->input('broughtby', _('Brought by'), $this->input('broughtby', _('Brought by'),
_('Text used for credits link in footer of each page')); _('Text used for credits link in footer of each page'));
$this->unli();
$this->li();
$this->input('broughtbyurl', _('Brought by URL'), $this->input('broughtbyurl', _('Brought by URL'),
_('URL used for credits link in footer of each page')); _('URL used for credits link in footer of each page'));
$this->unli();
$this->li();
$this->input('email', _('Email'), $this->input('email', _('Email'),
_('contact email address for your site')); _('contact email address for your site'));
$this->unli();
$timezones = array(); $timezones = array();
foreach (DateTimeZone::listIdentifiers() as $k => $v) { foreach (DateTimeZone::listIdentifiers() as $k => $v) {
@ -214,25 +224,43 @@ class SiteAdminPanelForm extends Form
asort($timezones); asort($timezones);
$this->li();
$this->out->dropdown('timezone', _('Default timezone'), $this->out->dropdown('timezone', _('Default timezone'),
$timezones, _('Default timezone for the site; usually UTC.'), $timezones, _('Default timezone for the site; usually UTC.'),
true, $this->value('timezone')); true, $this->value('timezone'));
$this->unli();
$this->li();
$this->out->dropdown('language', _('Language'), $this->out->dropdown('language', _('Language'),
get_nice_language_list(), _('Default site language'), get_nice_language_list(), _('Default site language'),
false, $this->value('language')); false, $this->value('language'));
$this->unli();
$this->li();
$this->out->checkbox('closed', _('Closed'), $this->out->checkbox('closed', _('Closed'),
(bool) $this->value('closed'), (bool) $this->value('closed'),
_('Is registration on this site prohibited?')); _('Is registration on this site prohibited?'));
$this->unli();
$this->li();
$this->out->checkbox('inviteonly', _('Invite-only'), $this->out->checkbox('inviteonly', _('Invite-only'),
(bool) $this->value('inviteonly'), (bool) $this->value('inviteonly'),
_('Is registration on this site only open to invited users?')); _('Is registration on this site only open to invited users?'));
$this->unli();
$this->li();
$this->out->checkbox('private', _('Private'), $this->out->checkbox('private', _('Private'),
(bool) $this->value('private'), (bool) $this->value('private'),
_('Prohibit anonymous users (not logged in) from viewing site?')); _('Prohibit anonymous users (not logged in) from viewing site?'));
$this->unli();
$this->out->elementEnd('ul');
} }
/** /**
@ -268,6 +296,16 @@ class SiteAdminPanelForm extends Form
return $value; return $value;
} }
function li()
{
$this->out->elementStart('li');
}
function unli()
{
$this->out->elementEnd('li');
}
/** /**
* Action elements * Action elements
* *