三个按钮作业

一、Click事件

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>click事件</title>
</head>
<body>
<form action="">
    <input id ='username' type="text">
    <input id='pwd'type="password">
    <input id ='i1'type="submit" value="提交">
</form>

<script src="jquery-3.3.1.min.js"></script>
<script>
    $('#i1').on('click',function () {
        alert(123);
    })
</script>
</body>
</html>

猜你喜欢

转载自www.cnblogs.com/mengbin0546/p/8933714.html