<a href="http://www.baidu.com" id="r">wwwwwwwww</a>
</p>
<script>
t.innerHTML=t.innerHTML.replace(/^w*/,'s')
//最后结果是输出一个s。为什么不是输出swwwwwwww? 大神解释下原理。
</script>
Copyright 2014-2025 https://www.php.cn/ All Rights Reserved | php.cn | 湘ICP备2023035733号
/^w*/g