6条回答
  •  轮回少年
    2021-01-21 21:23

    Why not use Jquery, It will be simplest solution in javascript.

    You can use like below

    $("a").on("click", function(event){
        alert('hahahha');
    });
    

    Refer this documentation. You can use Jquery 1.7 onwards.

提交回复
热议问题