$subject = 'qq2';
var_dump(preg_match('/^(?![0-9]+$)(?![a-zA-Z]+$)/', $subject));
如果要限定只能数字和字母的话, 限定下结尾
$subject = 'qq2';
var_dump(preg_match('/^(?![0-9]+$)(?![a-zA-Z]+$)[0-9a-zA-Z]+$/', $subject));
preg_match('/.*\d.*[a-zA-Z]|.*[a-z][A-Z].*\d/',$text);
$str = "hello1234";
preg_match("/[A-Za-z]/",$str)&& preg_match("/\d/",$str); //既有数字又有字母就是真