title: PHP Check domain of email being registered is a 'school.edu' address
body: <p>I need to write a function for a project i'm working on for fun, where we're making a site only accessible to students, staff, and alumni at an institution.</p>
  
  <p>Let's say the schools website is: school.edu.</p>
  
  <p>I'm having trouble writing a php filter that checks that the submitted email address has the domain of "school.edu"</p>
  
  <p>I'll use an example. Dude #1 has an email of user@mail.com and Dude #2 has an email at user@school.edu. I want to make sure that Dude 1 gets an error message, and Dude #2 has a successful registration. </p>
  
  <p>That's the gist of what I'm trying to do. In the near future the site will allow registration by another two locale schools: school2.edu and school3.edu. I will then need the checker to check the email against a small list (maybe an array?) of domains to verify that the email is of a domain name on the list.</p>