Created
May 23, 2013 08:51
-
-
Save SalvadorP/5633613 to your computer and use it in GitHub Desktop.
Regular expressions for checking mobile phones from spain and france.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$regexES = "/^((0034|\+34|34){1})*(?(?=6)(6){1}[0-9]{8}|(7){1}[1-9]{1}[0-9]{7})$/"; | |
$regexFR = "/^((0033|\+33|33){1})*(?(?=0)(06|07){1}[0-9]{8}|(6|7){1}[0-9]{8})$/"; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment