Register new account

<%= form_for(@user, html: {class: 'form-horizontal'}) do |f| %> <%= render partial: 'form_errors', locals: { what: @user } %>
<%= f.label :username, "Username", class: 'col-sm-2 control-label' %>
<%= f.text_field :username, class: 'form-control' %>

Username is only used for login and remains secret. Save this in your password manager.

<%= f.label :displayname, "Display name", class: 'col-sm-2 control-label' %>
<%= f.text_field :displayname, class: 'form-control' %>

Displayname is what other users see in messaging and product listings. It cannot be changed after the account is created. Must be different to username for security reasons.

<%= f.label :password, "Password", class: 'col-sm-2 control-label' %>
<%= f.password_field :password, class: 'form-control' %>

Minimum 8 characters.

<%= f.label :password_confirmation, "Confirm password", class: 'col-sm-2 control-label' %>
<%= f.password_field :password_confirmation, class: 'form-control' %>
<% if Rails.configuration.enable_mandatory_pgp_user_accounts %>
<%= f.label :publickey, "Public key", class: 'col-sm-2 control-label' %>
<%= f.text_area :publickey, rows: 10, class: 'form-control' %>

PGP public key is mandatory.

<% end %>
<%= f.label :currency, "Display currency", class: 'col-sm-2 control-label' %>
<%= f.select(:currency, Rails.configuration.currencies, {}, class: 'form-control') %>

Display product prices in this currency.

<%= f.label :timezone, class: 'col-sm-2 control-label' %>
<%= f.time_zone_select(:timezone, nil, {}, class: 'form-control') %>

Display times in your specified timezone.

<% if Rails.configuration.enable_vendor_registration_form %>
<%= f.label :vendor, "Vendor account", class: 'col-sm-2 control-label' %>
<%= f.check_box :vendor, id: 'vendor', class: 'checkbox' %>

Vendor accounts can list products but cannot make purchases.

<%= label_tag :vendor_code, "Vendor signup code", class: 'col-sm-2 control-label' %>
<%= text_field_tag :vendor_code, nil, class: 'form-control' %>

You must obtain a signup code and enter it here to create a vendor account.

<% end %>
CAPTCHA question:
<%= f.label :humanizer_answer, @user.humanizer_question, class: '' %> <%= f.text_field :humanizer_answer, class: 'form-control' %>
<%= f.hidden_field :humanizer_question_id %>
<%= f.submit "Create", id: 'submit', class: 'btn btn-primary' %>
<% end %>