正则取值name="xxxx"
使用正则取出 <input type= "text " name= "xxxx "/>
中name的value
------解决方案-------------------- <script type= "text/javascript ">
var name_p =/ <input[\S\s]+?name=\ "([^\ "]+)\ "[^> ]+> /i;
var name = ' <input type= "text " name= "xxxx "/> '.match(name_p)[1];
alert(name);
</script>