title: Accessing a subdomain of a website using email address as username and its password
body: <p>I have two subdomains for a school's website - 1. <code>staffmail.domainname.com</code> and 2. <code>studentmail.domainname.com</code>. Currently all email users of the website can access both mail portals... Both subdomains run RoundCube mail software. </p>
  
  <p>When a student user enters <code>staffmail.domainname.com</code>, it should prompt for login details. The student user enters his email address and password and then clicks on the login button. Thereafter the login gives an error. If a staff user enters their username and password and clicks on login the login works and the staff user will be taken to the mail application designed for the staff. </p>
  
  <p>Is there any way I can do this? Our website runs on cPanel with Softaculous apps. </p>