title: Test if a regular expression is a valid one in PHP
body: <p>I am writing a form validation class and wish to include regular expressions in the validation. Therefore, the regex provided isn't guaranteed to be valid.</p>
  
  <p>How can I (efficiently) check that the regex is valid?</p>