Skip to content

Instantly share code, notes, and snippets.

@cnnewjohn
Created October 27, 2014 13:30
Show Gist options
  • Save cnnewjohn/edd03eecae38efeba7ad to your computer and use it in GitHub Desktop.
Save cnnewjohn/edd03eecae38efeba7ad to your computer and use it in GitHub Desktop.
Valid.php PHP常用验证方法
<?php
class Valid
{
// 验证QQ号码是否合法
public static function qq($uin)
{
return preg_match('/^[1-9]{1}[0-9]{4,9}$/', $uin);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment