<?php$s = '+7 777 777777';$pattern = '/^\+[0-9]{1,3}\s[0-9]{1,6}\s[0-9\s]{5,8}$/u';echo preg_match($pattern, $s);?>
Standard input is empty
1
The brand new service which powers Ideone!
Widget for compiling and running the source code in a web browser!