Using email address as a username for secure zones

Version 1

    In order for the registered secure zone user to use their email address at login, their email address must also be stored in the Username field. This means that you will have to customise the web form once you insert it into a web page and with help of some simple JavaScript populate the Username field with the content of the Email Address field.


    To achieve this follow these steps:



    1. Insert the web form on to a web page in HTML form. Do not insert it as a module.


    2. Use CSS styles to hide (not remove) the Username field. You can do this by wrapping it in a HTML div element which is set to hidden. The code to hide the Username field is provided below:


     <div style="display:none;"><input type="text" name="Username" id="Username"></div>


    3. Add the following code to make the email address field automatically update the Username field when an email address is entered:


    <input type=text name="EmailAddress" onBlur="document.getElementById('Username').value=this.value;">