3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php if(function_exists('filter_var')) { $check = filter_var('info@test-test', FILTER_VALIDATE_EMAIL); } else { $check = preg_match('/^(?:[\w\!\#\$\%\&\'\*\+\-\/\=\?\^\`\{\|\}\~]+\.)*[\w\!\#\$\%\&\'\*\+\-\/\=\?\^\`\{\|\}\~]+@(?:(?:(?:[a-zA-Z0-9_](?:[a-zA-Z0-9_\-](?!\.)){0,61}[a-zA-Z0-9_-]?\.)+[a-zA-Z0-9_](?:[a-zA-Z0-9_\-](?!$)){0,61}[a-zA-Z0-9_]?)|(?:\[(?:(?:[01]?\d{1,2}|2[0-4]\d|25[0-5])\.){3}(?:[01]?\d{1,2}|2[0-4]\d|25[0-5])\]))$/', 'info@lindsey-dominique.be'); } echo $check;
Output for 5.2.0 - 5.2.8, 5.2.14 - 5.2.17, 5.3.3 - 5.6.28, hhvm-3.10.0 - 3.12.0, 7.0.0 - 7.1.0
Output for 5.2.9 - 5.2.13, 5.3.0 - 5.3.2
info@test-test
Output for 4.3.0 - 5.1.6
1