随笔分类 -  jquery特效

摘要:1,获取所有子节点 $(".parent").find('.child') 2,获取所有子节点,通过上层 div 的类名 , 获取上层 div 节点 $(".parent").find('.child').parents('.child-box') 3,获取完成后执行删除 $(".parent"). 阅读全文
posted @ 2020-05-06 00:17 武卡卡 阅读(2617) 评论(0) 推荐(1) 编辑
摘要:一 , js 获取元素(父节点,子节点,兄弟节点) var test = document.getElementById("test"); var parent = test.parentNode; // 父节点 var chils = test.childNodes; // 全部子节点 var f 阅读全文
posted @ 2020-05-05 23:11 武卡卡 阅读(714) 评论(0) 推荐(0) 编辑
摘要:<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8" /> <meta name="viewport" content="width=device-width, initial-scale=1.0" /> <title>Check 阅读全文
posted @ 2020-05-05 12:37 武卡卡 阅读(191) 评论(0) 推荐(0) 编辑
摘要:<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8" /> <meta name="viewport" content="width=device-width, initial-scale=1.0" /> <title>图片上传展 阅读全文
posted @ 2020-05-03 20:01 武卡卡 阅读(491) 评论(0) 推荐(0) 编辑
摘要:$(function () { (function() { //dom加载前执行的方法 })(jQuery); })实战: 1,情景 : index.html 判断 用户是否登录,如果登录则显示主页,未登录则弹出或者跳转到登录页面(主页内容隐藏) 。2,思路 : 由于以上这个方法不会阻碍dom渲染 阅读全文
posted @ 2020-04-13 12:17 武卡卡 阅读(922) 评论(0) 推荐(0) 编辑
摘要:使用 jQuery可以有效的兼容IE 浏览器 , 但jQuery从2.0开始不兼容IE8,最低支持IE9,所以需要引入更低的jQuery版本来兼容 <script type="text/javascript" src="<%=path%>/js/jquery-3.1.1.min.js"></scri 阅读全文
posted @ 2020-04-11 23:15 武卡卡 阅读(206) 评论(0) 推荐(0) 编辑
摘要:<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <meta http-equiv 阅读全文
posted @ 2020-01-05 18:57 武卡卡 阅读(1731) 评论(0) 推荐(0) 编辑
摘要:$("button").on("click",function(){ $('embed').remove(); $('body').append('<embed src="../../../sound/hit.mp3" autostart="true" hidden="true" loop="fal 阅读全文
posted @ 2019-08-01 17:05 武卡卡 阅读(1788) 评论(0) 推荐(0) 编辑
摘要:$(".userinfo-three:eq(0)").css({ "width": winWidth * 300 / 1080, "top": winWidth * 530 / 1080, "left": winWidth * 450 / 1080, }); $(".userinfo-three:e 阅读全文
posted @ 2019-07-12 15:47 武卡卡 阅读(3841) 评论(0) 推荐(0) 编辑
摘要:1,slider.js /** * slider插件可悬停控制 */ ; $(function ($, window, document, undefined) { Slider = function (container, options) { /* options = { auto: true, 阅读全文
posted @ 2019-07-06 17:49 武卡卡 阅读(300) 评论(0) 推荐(0) 编辑
摘要:1,index.html <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <me 阅读全文
posted @ 2019-07-03 20:29 武卡卡 阅读(430) 评论(0) 推荐(1) 编辑

喜欢请打赏

扫描二维码打赏

支付宝打赏

点击右上角即可分享
微信分享提示