Created
October 24, 2018 10:47
-
-
Save devoltt/ed92e142ed4a2d6fd96e185f00a5f3bc to your computer and use it in GitHub Desktop.
Popular regular expressions
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
<? | |
// Only letters, spaces and numbers | |
$str = preg_replace('/[^a-zа-яё\d\s]+/iu', '', $str); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment