aboutsummaryrefslogtreecommitdiff
path: root/views/default/forms/useradd.php
diff options
context:
space:
mode:
Diffstat (limited to 'views/default/forms/useradd.php')
-rw-r--r--views/default/forms/useradd.php51
1 files changed, 27 insertions, 24 deletions
diff --git a/views/default/forms/useradd.php b/views/default/forms/useradd.php
index 1119d180f..f4849618f 100644
--- a/views/default/forms/useradd.php
+++ b/views/default/forms/useradd.php
@@ -5,39 +5,42 @@
* @package Elgg
* @subpackage Core
*
- * @todo FIXME Forms 1.8: views in the forms/ directory should not be generating the <form> wrapper itself
*/
$admin_option = false;
if ((elgg_get_logged_in_user_entity()->isAdmin()) && ($vars['show_admin'])) {
$admin_option = true;
}
+?>
+<div>
+ <label><?php echo elgg_echo('name');?></label><br />
+ <?php echo elgg_view('input/text' , array('name' => 'name')); ?>
+</div>
+<div>
+ <label><?php echo elgg_echo('username'); ?></label><br />
+ <?php echo elgg_view('input/text' , array('name' => 'username')); ?>
+</div>
+<div>
+ <label><?php echo elgg_echo('email'); ?></label><br />
+ <?php elgg_view('input/text' , array('name' => 'email')); ?>
+</div>
+<div>
+ <label><?php echo elgg_echo('password'); ?></label><br />
+ <?php elgg_view('input/password' , array('name' => 'password')); ?>
+</div>
+<div>
+ <label><?php echo elgg_echo('passwordagain'); ?></label><br />
+ <?php elgg_view('input/password' , array('name' => 'password2')); ?>
+</div>
-$form_body = "<div><label>" . elgg_echo('name') . "</label><br />" . elgg_view('input/text' , array('name' => 'name')) . "</div>";
-$form_body .= "<div><label>" . elgg_echo('username') . "</label><br />" . elgg_view('input/text' , array('name' => 'username')) . "</div>";
-$form_body .= "<div><label>" . elgg_echo('email') . "</label><br />" . elgg_view('input/text' , array('name' => 'email')) . "</div>";
-$form_body .= "<div><label>" . elgg_echo('password') . "</label><br />" . elgg_view('input/password' , array('name' => 'password')) . "</div>";
-$form_body .= "<div><label>" . elgg_echo('passwordagain') . "</label><br />" . elgg_view('input/password' , array('name' => 'password2')) . "</div>";
-$form_body .= "<div>";
-
+<?php
if ($admin_option) {
- $form_body .= elgg_view('input/checkboxes', array('name' => "admin", 'options' => array(elgg_echo('admin_option'))));
- $form_body .= '</div><div>';
+ echo "<div>";
+ echo elgg_view('input/checkboxes', array('name' => "admin", 'options' => array(elgg_echo('admin_option'))));
+ echo "</div>";
}
-
-$form_body .= elgg_view('input/submit', array('name' => 'submit', 'value' => elgg_echo('register'))) . "</div>";
?>
-<div class="elgg-module elgg-module-inline">
- <div class="elgg-head">
- <h3><?php echo elgg_echo('adduser'); ?></h3>
- </div>
- <div class="elgg-body">
- <?php
- echo elgg_view('input/form', array(
- 'action' => "action/useradd",
- 'body' => $form_body,
- ));
- ?>
- </div>
+<div>
+ <?php echo elgg_view('input/submit', array('name' => 'submit', 'value' => elgg_echo('register'))); ?>
</div> \ No newline at end of file