{* Страница регистрации *}

{$meta_title = "Регистрация" scope=parent}

<div class="title">Регистрация</div>
<div class="well">
{if $error}
<div class="message_error">
	{if $error == 'empty_name'}Введите имя
	{elseif $error == 'empty_email'}Введите email
	{elseif $error == 'empty_password'}Введите пароль
	{elseif $error == 'user_exists'}Пользователь с таким email уже зарегистрирован
	{elseif $error == 'captcha'}Неверно введена капча
	{else}{$error}{/if}
</div>
{/if}

<form class="form register_form form-horizontal" method="post">
<div class="form-group">
	<label for="name" class="col-sm-2 control-label">Имя</label>
	<div class="col-sm-10"><input class="form-control" type="text" name="name" data-format=".+" data-notice="Введите имя" value="{$name|escape}" maxlength="255" /></div>
</div>
<div class="form-group">	
	<label for="email" class="col-sm-2 control-label">Email</label>
	<div class="col-sm-10"><input class="form-control" type="text" name="email" data-format="email" data-notice="Введите email" value="{$email|escape}" maxlength="255" /></div>
</div>
<div class="form-group">
    <label for="password" class="col-sm-2 control-label">Пароль</label>
    <div class="col-sm-10"><input class="form-control" type="password" name="password" data-format=".+" data-notice="Введите пароль" value="" /></div>
</div>
<div class="form-group">
    <div class="col-sm-2"><div class="captcha"><img src="captcha/image.php?{math equation='rand(10,10000)'}" alt=""/></div> </div>
    <div class="col-sm-2"><input class="form-control" class="input_captcha" id="comment_captcha" type="text" name="captcha_code" value="" data-format="\d\d\d\d" data-notice="Введите капчу"/></div>
</div>
	<input type="submit" class="btn btn-danger pull-right" name="register" value="Зарегистрироваться">
</form>
</div>
