title: How to validate multiple emails using Regex?
body: <p>After a quick research on the Stackoverflow, I wasn't able to find any solution for the multiple email validation using regex (split JS function is not applicable, but some reason back-end of the application waits for a string with emails separated by <code>;</code>).</p>
  
  <p>Here are the requirements:</p>
  
  <ol>
  <li>Emails should be validated using the following rule: <code>[A-Za-z0-9\._%-]+@[A-Za-z0-9\.-]+\.[A-Za-z]{2,4}</code></li>
  <li>Regex should accept <code>;</code> sign as a separator</li>
  <li>Emails can be written on multiple lines, finishing with <code>;</code></li>
  <li>Regex may accept the end of the line as <code>;</code></li>
  </ol>
  
  <p>I come up with this solution:</p>
  
  <pre>
  ^[A-Za-z0-9\._%-]+@[A-Za-z0-9\.-]+\.[A-Za-z]{2,4}(?:[;][A-Za-z0-9\._%-]+@[A-Za-z0-9\.-]+\.[A-Za-z]{2,4}?)*
  </pre>
  
  <p>but it doesn't work for point #3-4</p>
  
  <p>So here are cases that are OK:</p>
  
  <pre>
   1. john@smith.com;john@smith.com
   2. john@smith.com;john@smith.com;
   3. john@smith.com;
      john@smith.com;
      jjoh@smith.com;
  </pre>
  
  <p>Here are cases that are definetely NOT OK:</p>
  
  <pre>
    1. john@smith.com jackob@smith.com
    2. jackob@smith.com,
    3. daniels@mail.com
       smth@mail.com
  </pre>
  
  <p>All sort of help will be appreciated</p>