aboutsummaryrefslogtreecommitdiff
path: root/views/default/account/forms/useradd.php
diff options
context:
space:
mode:
authormarcus <marcus@36083f99-b078-4883-b0ff-0f9b5a30f544>2008-08-11 10:52:20 +0000
committermarcus <marcus@36083f99-b078-4883-b0ff-0f9b5a30f544>2008-08-11 10:52:20 +0000
commit6315f728e83cf8b35ce4451fe7e0d74cc4f5f7be (patch)
tree5350d68206722b5c44ebd6e85e0f6ee4ec3f8dd8 /views/default/account/forms/useradd.php
parentbf1e40afcf8da4ea6e9d663531dfe3bc934483dc (diff)
downloadelgg-6315f728e83cf8b35ce4451fe7e0d74cc4f5f7be.tar.gz
elgg-6315f728e83cf8b35ce4451fe7e0d74cc4f5f7be.tar.bz2
Refs #210 & #211
git-svn-id: https://code.elgg.org/elgg/trunk@1820 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'views/default/account/forms/useradd.php')
-rw-r--r--views/default/account/forms/useradd.php33
1 files changed, 13 insertions, 20 deletions
diff --git a/views/default/account/forms/useradd.php b/views/default/account/forms/useradd.php
index c170f30f1..28e5d3d30 100644
--- a/views/default/account/forms/useradd.php
+++ b/views/default/account/forms/useradd.php
@@ -13,29 +13,22 @@
$admin_option = false;
if (($_SESSION['user']->admin) && ($vars['show_admin']))
$admin_option = true;
+
+ $form_body = "<p><label>" . elgg_echo('name') . "<br />" . elgg_view('input/text' , array('internalname' => 'name')) . "</label><br />";
+
+ $form_body .= "<label>" . elgg_echo('email') . "<br />" . elgg_view('input/text' , array('internalname' => 'email')) . "</label><br />";
+ $form_body .= "<label>" . elgg_echo('username') . "<br />" . elgg_view('input/text' , array('internalname' => 'username')) . "</label><br />";
+ $form_body .= "<label>" . elgg_echo('password') . "<br />" . elgg_view('input/password' , array('internalname' => 'password')) . "</label><br />";
+ $form_body .= "<label>" . elgg_echo('passwordagain') . "<br />" . elgg_view('input/password' , array('internalname' => 'password2')) . "</label><br />";
+
+ if ($admin_option)
+ $form_body .= elgg_view('input/checkboxes', array('internalname' => "admin", 'options' => array(elgg_echo('admin_option'))));
+
+ $form_body .= elgg_view('input/submit', array('internalname' => 'submit', 'value' => elgg_echo('register'))) . "</p>";
?>
<div id="add-box">
<h2><?php echo elgg_echo('adduser'); ?></h2>
- <form action="<?php echo $vars['url']; ?>action/useradd" method="POST">
- <p><label><?php echo elgg_echo('name'); ?>:
- <?php echo elgg_view('input/text', array('internalname' => 'name')); ?></label><br />
- <label><?php echo elgg_echo('email'); ?>:
- <?php echo elgg_view('input/email', array('internalname' => 'email')); ?></label><br />
- <label><?php echo elgg_echo('username'); ?>:
- <?php echo elgg_view('input/text', array('internalname' => 'username')); ?></label><br />
- <label><?php echo elgg_echo('password'); ?>:
- <?php echo elgg_view('input/password', array('internalname' => 'password')); ?></label><br />
- <label><?php echo elgg_echo('passwordagain'); ?>:
- <?php echo elgg_view('input/password', array('internalname' => 'password2')); ?></label><br />
- <?php
- if ($admin_option) {
-?>
- <label><?php echo elgg_echo('admin_option'); ?> <input type="checkbox" name="admin" /></label> <br />
-<?php
- }
- ?>
- <input type="submit" name="submit" class="submit_button" value="<?php echo elgg_echo('adduser'); ?>" /></p>
- </form>
+ <?php echo elgg_view('input/form', array('action' => "{$vars['url']}action/useradd", 'body' => $form_body)) ?>
</div> \ No newline at end of file