I am experiencing a strange problem with a regular expression I have already used before. The goal is to allow the user to enter his name, with letters, hyphen, and apostrophes if needed in a php form. My regex is:
"/^[\w\s'àáâãäåçèéêëìíîïðòóôõöùúûüýÿ-]+$/i"
But... everything is allowed but the apostrophe. Escaping it will not change. Why?