读书人

怎么取onClick的值

发布时间: 2012-02-03 22:02:47 作者: rapoo

如何取onClick的值!
<input id= "1441 " onClick= "aaabbbccc " type= "button " value= "ONCLICK ">
<input onClick= "alert(document.all( '1441 ').onClick); " type= "button " value= "我想取 'ONCLICK '的ONCLICK内容 ">

[解决办法]
可以改,LZ 想怎么改?说得清楚些!

譬如,L@_@K!

<input id= "1441 " onclick= "alert( '我取! '); " type= "button " value= "ONCLICK ">
<input id= "5151 " onclick= "alert(document.all( '1441 ').onclick); " type= "button " value= "我想取 'ONCLICK '的ONCLICK内容 ">
<script type= "text/javascript ">
<!--
document.all( '5151 ').onclick = function() {
var f0 = document.all( '1441 ').onclick;
document.all( '1441 ').onclick = function() {
f0();
alert( '我再取! ');
};
};
//-->
</script>

读书人网 >JavaScript

热点推荐