I have a function (that works) and checks if an email address is valid. I understand how most of it is working except for the part that actually tests when there is a decent looking email.

How does this work:

```
 if ( preg_match("/[a-z0-9!#$%&'*+\/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+\/=?^_`{|}~-]+)*@(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?/i", $email) ) {
        $valid_address = true;
      } else {
        $valid_address = false;
      }
    } 

```

I don't really understand preg\_match, so this looks like pretty much random characters.