但是我又必须传参数,可以用匿名函数包装一下需要调用的函数,如下所示:
这样就能把参数id传进去了,延迟效果也会正常产生。
function ajax_get_mediaList(){
var id = document.getElementById("selectPublisher").value;
setTimeout(function(){ajax_publisher_change(id);},1000);
}
吴斯
unread,
Aug 18, 2008, 5:45:05 AM8/18/08
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message