made login a template, added i18n helper