初识jQuery及公式

jQuery

JavaScript
jQuery库,里面存在大量的javascript函数

获取jQuery

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <!--cdn引入-->
<!--    <script src="https://apps.bdimg.com/libs/jquery/2.1.4/jquery.min.js"></script>-->
    <script src="lib/jquery-3.6.0.js"></script>
</head>
<body>
<!--公式:$(selector).action()-->
<a href="" id="text-jquery">点我</a>

<script>
    document.getElementById('id');

    //选择器就是css的选择器
    $('#test-jquery').click(function () {
        alert('hello, jQuery');
    })
</script>
</body>
</html>

相关文章

1.第一步 设置响应头 header(&#39;Access-Control-Allow...
$.inArray()方法介绍 $.inArray()函数用于在数组中搜索指定的...
jquery.serializejson.min.js的妙用 关于这个jquery.seriali...
JS 将form表单数据快速转化为object对象(json对象) jaymou...
jQuery插件之jquery.spinner数字智能增减插件 参考地址:http...