In the examples they're used mixed:


<input id="username" type="text" name="username"
{%- if account is defined %} value="{{ account.username }}"{% endif -%}>


 <input id="loginName" type="text" name="loginName"
    value="{{ craft.session.rememberedUsername }}">

For the login form, a field named "username" can not be used, it should be "loginName". What is the difference between the two?


Because you can login with either your email address or your username. And some sites will be forcing the username to be the email address.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.