]> git.mxchange.org Git - quix0rs-gnu-social.git/commitdiff
fix checkbox for license
authorEvan Prodromou <evan@prodromou.name>
Tue, 15 Jul 2008 21:42:49 +0000 (17:42 -0400)
committerEvan Prodromou <evan@prodromou.name>
Tue, 15 Jul 2008 21:42:49 +0000 (17:42 -0400)
darcs-hash:20080715214249-84dde-ed5f9b38a93e9fcfd5c6772fb1c784696d3a435a.gz

actions/register.php

index 76e6ede5541e00d2b5d103599631dda1839da96a..1829fa03d5f3b9b1dd96208b7f21b889434e58fe 100644 (file)
@@ -225,10 +225,14 @@ class RegisterAction extends Action {
                                                $this->boolean('rememberme'),
                                _('Automatically login in the future; not for shared computers!'));
                common_element_start('p');
-               common_element('input', array('type' => 'checkbox',
-                                                                         'id' => 'license',
-                                                                         'name' => 'license',
-                                                                         'value' => ($this->boolean('license')) ? 'true' : 'false'));
+               $attrs = array('type' => 'checkbox',
+                                          'id' => 'license',
+                                          'name' => 'license',
+                                          'value' => 'true');
+               if ($this->boolean('license')) {
+                       $attrs['checked'] = 'checked';
+               }
+               common_element('input', $attrs);
            common_text(_('My text and files are available under '));
                common_element('a', array(href => $config['license']['url']),
                                           $config['license']['title']);