shenma 发表于 2011-12-28 20:17:49

正则匹配

if(preg_match('/[><,\[\]\{\}\?\/\+=|\\\'\:\.\;\~\!\@\@\#\*\$\%\^\&\(\)\`\-\,\。\!\“\《\》\?\、\¥\…\—\(\)]/', $data['search']))
            {
                echo "<script>alert('请输入有意义的字符!');history.go(-1);</script>";
            }
页: [1]
查看完整版本: 正则匹配