面向对象,扩展内置对象方法为何不行
String.prototype={
constructor:this,
run:function () {
alert("success!");
}
};
var n="####";
n.run();
Copyright 2014-2026 https://www.php.cn/ All Rights Reserved | php.cn | 湘ICP备2023035733号
用这个吧..