Does this sort of regex within php preg_match look like a working validation?
if (preg_match("/^[a-zÇÑQÀÁÈÉÍÌÏÓÒÚÙÜ]|[\t]+$/i]",$_POST["i1"])) {
$_SESSION['i1'] = $_POST["i1"];
}
php regex preg_match validation
Moderator: General Moderators
-
bradleybebad
- Forum Newbie
- Posts: 1
- Joined: Thu Aug 19, 2010 2:54 pm
Re: php regex preg_match validation
A working validation for what? It does check (quite clumsily) if a string contains only a certain set of characters. Whether this is what you want, only you can tell 