随笔分类 -  JavaScript

摘要:视口是红色线包围的部分 阅读全文
posted @ 2016-12-23 15:05 ifIhaveWings 阅读(734) 评论(0) 推荐(0)
摘要: 阅读全文
posted @ 2016-12-21 10:15 ifIhaveWings 阅读(126) 评论(0) 推荐(0)
摘要:1.媒体查询:缺点是适配机型不完完整2.用js去适配可以适配所有的机型(function (doc, win) { var docEl = doc.documentElement, resizeEvt = 'orientationchange' in window ? 'orientationchange' : 'resize', recalc = function () {... 阅读全文
posted @ 2016-07-08 16:51 ifIhaveWings 阅读(216) 评论(0) 推荐(0)
摘要:<!DOCTYPE html><html><head><meta charset="utf-8" /><style> * {margin:0; padding:0; list-style: none; } .main { position: relative;} .clear { clear: bo 阅读全文
posted @ 2016-07-05 16:09 ifIhaveWings 阅读(388) 评论(0) 推荐(0)
摘要:<!DOCTYPE html><html><head><meta charset="utf-8" /><style> * {margin:0; padding:0; list-style: none; } .main { position: relative;} .clear { clear: bo 阅读全文
posted @ 2016-07-05 16:09 ifIhaveWings 阅读(258) 评论(0) 推荐(0)
摘要:1 //按照对象的属性值排序 2 var person =[ 3 {name:'Zach',age:26,tag:1}, 4 {name:'Tom',age:29,tag:2}, 5 {name:'Kate',age:30,tag:3}, 6 {name:'Gates',age:31,tag:4}, 7... 阅读全文
posted @ 2016-05-20 19:50 ifIhaveWings 阅读(1243) 评论(0) 推荐(0)
摘要:原文地址:http://www.cnblogs.com/hoojo/archive/2012/02/16/2354663.html jQuery 获取屏幕高度、宽度 做手机Web开发做浏览器兼容用到了,所以在网上找了些汇总下。 alert($(window).height()); //浏览器当前窗口 阅读全文
posted @ 2016-05-06 14:58 ifIhaveWings 阅读(219) 评论(0) 推荐(0)
摘要:1.javascript包含ECMAscript、DOM、BOM 阅读全文
posted @ 2016-04-14 13:02 ifIhaveWings 阅读(163) 评论(0) 推荐(0)