aboutsummaryrefslogtreecommitdiff
path: root/actions
diff options
context:
space:
mode:
authorben <ben@36083f99-b078-4883-b0ff-0f9b5a30f544>2008-04-01 14:20:55 +0000
committerben <ben@36083f99-b078-4883-b0ff-0f9b5a30f544>2008-04-01 14:20:55 +0000
commit9391179df8ba6ed1595de7de533f633d99d57b35 (patch)
treee2ddcf5ac254a5a37a6722e9e7eeb8f2fc67367b /actions
parentb1486d73ab4996931afa0d37fa9e5d09a4a88765 (diff)
downloadelgg-9391179df8ba6ed1595de7de533f633d99d57b35.tar.gz
elgg-9391179df8ba6ed1595de7de533f633d99d57b35.tar.bz2
User registration gubbins
git-svn-id: https://code.elgg.org/elgg/trunk@308 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'actions')
-rw-r--r--actions/login.php2
-rw-r--r--actions/logout.php2
-rw-r--r--actions/register.php28
3 files changed, 30 insertions, 2 deletions
diff --git a/actions/login.php b/actions/login.php
index dbc84bab5..e79799a30 100644
--- a/actions/login.php
+++ b/actions/login.php
@@ -1,7 +1,7 @@
<?php
/**
- * Elgg login action page
+ * Elgg login action
*
* @package Elgg
* @subpackage Core
diff --git a/actions/logout.php b/actions/logout.php
index 99ef5abf6..2bcb538de 100644
--- a/actions/logout.php
+++ b/actions/logout.php
@@ -1,7 +1,7 @@
<?php
/**
- * Elgg logout action page
+ * Elgg logout action
*
* @package Elgg
* @subpackage Core
diff --git a/actions/register.php b/actions/register.php
new file mode 100644
index 000000000..2e8c5b414
--- /dev/null
+++ b/actions/register.php
@@ -0,0 +1,28 @@
+<?php
+
+ /**
+ * Elgg registration action
+ *
+ * @package Elgg
+ * @subpackage Core
+ * @license http://www.gnu.org/licenses/old-licenses/gpl-2.0.html GNU Public License version 2
+ * @author Curverider Ltd
+ * @copyright Curverider Ltd 2008
+ * @link http://elgg.org/
+ */
+
+ // Get variables
+ $username = get_input($username);
+ $password = get_input($password);
+ $password2 = get_input($password2);
+ $email = get_input($email);
+ $name = get_input($name);
+
+ // For now, just try and register the user
+ if (register_user($username, $password, $name, $email)) {
+ system_message(sprintf(elgg_echo("registerok"),$CONFIG->sitename));
+ } else {
+ system_message(elgg_echo("registerbad"));
+ }
+
+?> \ No newline at end of file