Fake “click” to activate an onclick method

前端 未结 11 952
醉话见心
醉话见心 2020-11-28 10:11

I have an element with an onclick method.

I would like to activate that method (or: fake a click on this element) within another function.

I

11条回答
  •  北海茫月
    2020-11-28 10:42

    This is a perfect example of where you should use a javascript library like Prototype or JQuery to abstract away the cross-browser differences.

提交回复
热议问题