摘要: //小程序跳转小程序 wx.navigateToMiniProgram({ appId: '目标小程序appid', path: '目标小程序页面路径', //develop开发版;trial体验版;release正式版 envVersion: 'release', success(res) { / 阅读全文
posted @ 2023-11-03 10:43 心有猛虎,细嗅蔷薇。 阅读(64) 评论(0) 推荐(0) 编辑
摘要: <meta name="viewport" content="width=device-width,initial-scale=0.3,maximum-scale=1,user-scalable=0"> //兼容ios document.addEventListener('gesturestart' 阅读全文
posted @ 2023-09-18 17:11 心有猛虎,细嗅蔷薇。 阅读(8) 评论(0) 推荐(0) 编辑
摘要: document.addEventListener('click', (e) => { let screenDoc = document.querySelector('.screen-box'); if (screenDoc && !screenDoc.contains(e.target)) { / 阅读全文
posted @ 2022-01-27 16:47 心有猛虎,细嗅蔷薇。 阅读(914) 评论(0) 推荐(0) 编辑
摘要: //上传头像到服务器 function uploadFile() { console.log(344) var pic = $('#upload')[0].files[0]; var file = new FormData(); file.append('image', pic); $.ajax({ 阅读全文
posted @ 2021-12-14 13:45 心有猛虎,细嗅蔷薇。 阅读(176) 评论(0) 推荐(0) 编辑
摘要: 窗口可视区域宽度: document.documentElement.clientWidth || document.body.clientWidth; 窗口可视区域高度: document.documentElement.clientHeight || document.body.clientHe 阅读全文
posted @ 2020-12-30 09:49 心有猛虎,细嗅蔷薇。 阅读(473) 评论(0) 推荐(0) 编辑
摘要: function getQueryString(name) { var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)", "i"); var r = window.location.search.substr(1).match(reg); if ( 阅读全文
posted @ 2020-11-03 17:46 心有猛虎,细嗅蔷薇。 阅读(78) 评论(0) 推荐(0) 编辑
摘要: 阅读全文
posted @ 2020-08-31 21:14 心有猛虎,细嗅蔷薇。 阅读(120) 评论(0) 推荐(0) 编辑
摘要: //判断手机设备 var u = navigator.userAgent; if(u.match(/iPhone/i) || u.match(/Android/i) || u.match(/iPod/i)){ console.log('手持设备') } //判断IPad设备 if(navigator 阅读全文
posted @ 2020-08-21 11:50 心有猛虎,细嗅蔷薇。 阅读(208) 评论(0) 推荐(0) 编辑
摘要: function getCookie(name){ var arr,reg=new RegExp("(^| )"+name+"=([^;]*)(;|$)"); if(arr=document.cookie.match(reg)){ return unescape(arr[2]); }else{ re 阅读全文
posted @ 2020-08-20 18:16 心有猛虎,细嗅蔷薇。 阅读(257) 评论(0) 推荐(0) 编辑
摘要: js方法: parent.document; jquery方法: $('#test',parent.document); //此处的选择器为父页面的选择器 阅读全文
posted @ 2020-08-20 10:45 心有猛虎,细嗅蔷薇。 阅读(2235) 评论(0) 推荐(0) 编辑
点击右上角即可分享
微信分享提示