Two Methods
There seem to be two methods to create a standalone member registration form. The original method relies on duplicating the HTML markup of the registration form and the alternate method relies on calling the native ExpressionEngine module to build the registration form code.
Method One
This updates the EE1 Standalone Registration Form Wiki entry and describes how to create a registration form inside one of your templates (rather than pointing the user to the standard registration template).
There are two ways to retrieve the action ID of the member registration module. You may either place some PHP directly in your EE templates, or you can rely on a module such as VWM Get Action. Embeding PHP in a template requires that you put this code at the top of your template:
<?php
$this->EE =& get_instance();
$action_id = $this->EE->functions->fetch_action_id('Member', 'register_member');
?>
Remember to enable PHP in the template, and set processing to input. We will use this id number in a hidden field in the registration form.
You can put the form itself anywhere in your template. The following code was taken from the registration form in the Default Member Profile Templates group (which you can find under Design->Themes->Member Profile Templates->Default), so you will see CSS classes that refer back to the Member Profile Templates stylesheet. You can, of course, copy these classes to your own stylesheet and change them to match your look.
<form id="register_member_form" method="post" action="http://your site's URL">
<div class='hiddenFields'>
<input type="hidden" name="XID" value={XID_HASH} />
<input type="hidden" name="ACT" value="<?php echo $action_id; ?>" />
<input type="hidden" name="RET" value="http://the URL where the member is directed after registering" />
<input type="hidden" name="FROM" value="" />
<input type="hidden" name="site_id" value="1" />
</div> <!-- closes out hiddenFields -->
<table class="tableBorder" border='0' cellspacing='0' cellpadding='0'>
<tr>
<td class='profileHeadingBG' colspan='2'>
<div class="tableHeading">
Member Registration
</div>
</td>
</tr><!-- end table heading row -->
<tr>
<td class='tableCellTwo'>
<div class='defaultBold'>
<span class="highlight">*</span>
Username
</div>
<div class='itempad'>Usernames must be at least 4 characters long
</div>
</td>
<td class='tableCellOne'>
<input type="text" name="username" value="" maxlength="32" class="input" size="25" style="width:300px" />
</td>
</tr><!-- end username row -->
<tr>
<td class='tableCellTwo'>
<div class='defaultBold'>
<span class="highlight">*</span>
Password
</div>
<div class='itempad'>
Passwords must be at least 5 characters long
</div>
</td>
<td class='tableCellOne'>
<input type="password" name="password" value="" maxlength="32" class="input" size="25" style="width:300px" />
</td>
</tr><!-- end password row -->
<tr>
<td class='tableCellTwo'>
<div class='defaultBold'>
<span class="highlight">*</span>
Password Confirm
</div>
</td>
<td class='tableCellOne'>
<input type="password" name="password_confirm" value="" maxlength="32" class="input" size="25" style="width:300px" />
</td>
</tr><!-- end confirm password row -->
<tr>
<td class='tableCellTwo'>
<div class='defaultBold'>
<span class="highlight">*</span>
Screen Name
</div>
<div class='itempad'>
If you leave this field blank, your screen name will be the same as your username
</div>
</td>
<td class='tableCellOne'>
<input type="text" name="screen_name" value="" maxlength="100" class="input" size="25" style="width:300px" />
</td>
</tr><!-- end screen name row -->
<tr>
<td class='tableCellTwo'>
<div class='defaultBold'>
<span class="highlight">*</span>
Email Address
</div>
</td>
<td class='tableCellOne'>
<input type="text" name="email" value="" maxlength="120" class="input" size="40" style="width:300px" />
</td>
</tr><!-- end e-mail row -->
<tr>
<td class='tableCellTwo'>
<div class='defaultBold'>
<span class="highlight">*</span>
Confirm Email Address
</div>
</td>
<td class='tableCellOne'>
<input type="text" name="email_confirm" value="" maxlength="120" class="input" size="40" style="width:300px" />
</td>
</tr><!-- end confirm e-mail row -->
<tr>
<td colspan='2' class='tableCellOne'>
<div class="itempadbig">
<div class="itempad">
<div class='defaultBold'>
Terms of Service
</div>
</div><!-- closes out itempad -->
<textarea name='rules' style='width:100%' class='textarea' rows='8' cols='90' readonly="readonly">
All messages posted at this site express the views of the author, and do not necessarily reflect the views of the owners and administrators of this site.
By registering at this site you agree not to post any messages that are obscene, vulgar, slanderous, hateful, threatening, or that violate any laws. We will permanently ban all users who do so.
We reserve the right to remove, edit, or move any messages for any reason.
</textarea>
</div><!-- closes out itempadbig -->
</td>
</tr><!-- closes out terms of service row -->
<tr>
<td colspan='2' class='tableCellOne'>
{if captcha}
<p><span class="highlight">*</span> {lang:captcha}</p>
<p>{captcha}<br />
<input type="text" name="captcha" value="" size="20" maxlength="20" style="width:140px;" />
</p>
{/if}
<p><input type='checkbox' name='accept_terms' value='y' />
<span class="highlight">*</span>
<span class="alert">I agree to the terms of service</span>
</p>
<p><input type="submit" value="Submit" class="submit" />
</p>
<p><span class="highlight">*</span>
Indicates required fields
</p>
</td>
</tr>
</table>
</form>
Method Two
Using the the alternate method you would simply place the following code in your EE template:
{exp:member:registration_form}{/exp:member:registration_form}
Once you visit this page, however, you will notice that only some of the language text has been replaced. If you take a look at the registration_form method inside system\expressionengine\modules\member\mod.member_register.php you can see that only a handful of language lines are getting processed here.
However, you can still manually update all the markup and language text for this registration template. In the EE control panel go to Design > Themes > Member Profile Templates > Registration Form. Here you can edit all the markup for this form.
Method Three
Use AJAX Registration add-on. This plugin allows you to display member registration form and forgot password form in ExpressionEngine’s templates and submit them without reloading of the page.
