只能是数字或字母或-或_ /^[\w-_]+$/文件路径验证 /^[a-zA-Z]\:[\\a-zA-Z0-9_\\]+[\.]?[a-zA-Z0-9_]+$/验证只能是数字 /^\+?[1-9][0-9]*$/ 转载于:https://www.cnblogs.com/chenmenghappy/p/3270057.html