摘要: 动态组合的正则表达式<script type="text/javascript">var m = 7;var n = 2;var reg = new RegExp("^[1-9]{0,"+m+"}\\.\\d{0,"+n+"}$");alert(reg.test("1231.02333"));alert(reg.test("143442.34"));alert(reg.test("2222"));</script> "^\ 阅读全文
posted @ 2012-10-04 20:44 星火卓越 阅读(103) 评论(0) 推荐(0) 编辑