| 1 | <?php
|
|---|
| 2 | /**
|
|---|
| 3 | * Users Register
|
|---|
| 4 | *
|
|---|
| 5 | * PHP version 5
|
|---|
| 6 | *
|
|---|
| 7 | * LICENSE: Hotaru CMS is free software: you can redistribute it and/or
|
|---|
| 8 | * modify it under the terms of the GNU General Public License as
|
|---|
| 9 | * published by the Free Software Foundation, either version 3 of
|
|---|
| 10 | * the License, or (at your option) any later version.
|
|---|
| 11 | *
|
|---|
| 12 | * Hotaru CMS is distributed in the hope that it will be useful, but WITHOUT
|
|---|
| 13 | * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
|---|
| 14 | * FITNESS FOR A PARTICULAR PURPOSE.
|
|---|
| 15 | *
|
|---|
| 16 | * You should have received a copy of the GNU General Public License along
|
|---|
| 17 | * with Hotaru CMS. If not, see http://www.gnu.org/licenses/.
|
|---|
| 18 | *
|
|---|
| 19 | * @category Content Management System
|
|---|
| 20 | * @package HotaruCMS
|
|---|
| 21 | * @author Nick Ramsay <admin@hotarucms.org>
|
|---|
| 22 | * @copyright Copyright (c) 2009, Hotaru CMS
|
|---|
| 23 | * @license http://www.gnu.org/copyleft/gpl.html GNU General Public License
|
|---|
| 24 | * @link http://www.hotarucms.org/
|
|---|
| 25 | */
|
|---|
| 26 |
|
|---|
| 27 | if ($h->cage->post->getAlpha('users_type') == 'register') {
|
|---|
| 28 | $username_check = $h->cage->post->testUsername('username');
|
|---|
| 29 | $password_check = "";
|
|---|
| 30 | $password2_check = "";
|
|---|
| 31 | $email_check = $h->cage->post->testEmail('email');
|
|---|
| 32 | } else {
|
|---|
| 33 | $username_check = "";
|
|---|
| 34 | $password_check = "";
|
|---|
| 35 | $password2_check = "";
|
|---|
| 36 | $email_check = "";
|
|---|
| 37 | }
|
|---|
| 38 | ?>
|
|---|
| 39 | <h2><?php echo $h->lang["user_signin_register"]; ?></h2>
|
|---|
| 40 |
|
|---|
| 41 | <?php echo $h->showMessages(); ?>
|
|---|
| 42 |
|
|---|
| 43 | <?php $h->pluginHook('user_signin_register_pre_register_form'); ?>
|
|---|
| 44 |
|
|---|
| 45 | <div class='user_login_reg'>
|
|---|
| 46 | <?php echo $h->lang["user_signin_register_instructions"]; ?>
|
|---|
| 47 |
|
|---|
| 48 | <form name='register_form' action='<?php echo BASEURL; ?>index.php?page=register' method='post'>
|
|---|
| 49 | <table>
|
|---|
| 50 | <tr><td>
|
|---|
| 51 | <?php echo $h->lang["user_signin_register_username"]; ?> </td><td><input type='text' size=30 name='username' value='<?php echo $username_check; ?>' />
|
|---|
| 52 | <br /><small><?php echo $h->lang["user_signin_register_username_error_short"]; ?></small>
|
|---|
| 53 | </td></tr>
|
|---|
| 54 |
|
|---|
| 55 | <tr><td>
|
|---|
| 56 | <?php echo $h->lang["user_signin_register_email"]; ?> </td><td><input type='text' size=30 name='email' value='<?php echo $email_check; ?>' />
|
|---|
| 57 | </td></tr>
|
|---|
| 58 |
|
|---|
| 59 | <tr><td>
|
|---|
| 60 | <?php echo $h->lang["user_signin_register_password"]; ?> </td><td><input type='password' size=30 name='password' value='<?php echo $password_check; ?>' />
|
|---|
| 61 | <br /><small><?php echo $h->lang["user_signin_register_password_error_short"]; ?></small>
|
|---|
| 62 | </td></tr>
|
|---|
| 63 |
|
|---|
| 64 | <tr><td>
|
|---|
| 65 | <?php echo $h->lang["user_signin_register_password_verify"]; ?> </td><td><input type='password' size=30 name='password2' value='<?php echo $password2_check; ?>' />
|
|---|
| 66 | </td></tr>
|
|---|
| 67 |
|
|---|
| 68 | <?php $h->pluginHook('user_signin_register_register_form'); ?>
|
|---|
| 69 |
|
|---|
| 70 | <?php
|
|---|
| 71 | if ($h->vars['useRecaptcha']) {
|
|---|
| 72 | $user_signin_settings = $h->getSerializedSettings('user_signin');
|
|---|
| 73 | $recaptcha_pubkey = $user_signin_settings['recaptcha_pubkey'];
|
|---|
| 74 | echo "<tr><td colspan=2>" . recaptcha_get_html($recaptcha_pubkey) . "</td></tr>";
|
|---|
| 75 | }
|
|---|
| 76 | ?>
|
|---|
| 77 |
|
|---|
| 78 | <input type='hidden' name='users_type' value='register' />
|
|---|
| 79 | <input type='hidden' name='page' value='register'>
|
|---|
| 80 | <input type='hidden' name='csrf' value='<?php echo $h->csrfToken; ?>' />
|
|---|
| 81 | <tr><td> </td><td style='text-align:right;'><input type='submit' class='submit' value='<?php echo $h->lang['user_signin_register_form_submit']; ?>' /></td></tr>
|
|---|
| 82 | </table>
|
|---|
| 83 | </form>
|
|---|
| 84 | </div>
|
|---|