会员
众包
新闻
博问
闪存
赞助商
HarmonyOS
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
过河的象
导航
博客园
首页
新随笔
联系
订阅
管理
公告
[置顶]
随便写个玩玩。
摘要: iphone手机不支持fixed 有没有更好的办法。
阅读全文
posted @ 2017-04-28 09:35 小小小小小菜鸡程序员
阅读(68)
评论(0)
推荐(0)
2017年4月28日
性能优化2
摘要: 1. 尽可能的减少 HTTP 的请求数 [content]2. 使用 CDN(Content Delivery Network) [server]3. 添加 Expires 头(或者 Cache-control ) [server]4. Gzip 组件 [server]5. 将 CSS 样式放在页面
阅读全文
posted @ 2017-04-28 17:10 小小小小小菜鸡程序员
阅读(111)
评论(0)
推荐(0)
去掉覆盖chrome默认填充的那坨黄
摘要: input:-webkit-autofill { -webkit-text-fill-color: $gray-96; @include box-shadow(0 0 0px 1000px $main-border-color inset); }
阅读全文
posted @ 2017-04-28 17:09 小小小小小菜鸡程序员
阅读(103)
评论(0)
推荐(0)
获取浏览器的各种属性
摘要: 网页可见区域宽: document.body.clientWidth;网页可见区域高: document.body.clientHeight;网页可见区域宽: document.body.offsetWidth (包括边线的宽);网页可见区域高: document.body.offsetHeight
阅读全文
posted @ 2017-04-28 17:07 小小小小小菜鸡程序员
阅读(117)
评论(0)
推荐(0)
去除空格
摘要: str为要去除空格的字符串:去除所有空格: str = str.replace(/\s+/g,""); 去除两头空格: str = str.replace(/^\s+|\s+$/g,"");去除左空格:str=str.replace( /^\s*/, '');去除右空格:str=str.replac
阅读全文
posted @ 2017-04-28 17:07 小小小小小菜鸡程序员
阅读(113)
评论(0)
推荐(0)
禁止鼠标右键点击事件
摘要: <!DOCTYPE html><html> <head> <meta charset="UTF-8"> <title></title> <script language=JavaScript> document.oncontextmenu = new Function("event.returnVa
阅读全文
posted @ 2017-04-28 17:06 小小小小小菜鸡程序员
阅读(130)
评论(0)
推荐(0)
把视频当成背景
摘要: <!DOCTYPE html><html> <head> <meta charset="UTF-8"> <title></title> <style type="text/css"> *{margin: 0;padding: 0;} h1{margin: 50px auto;width: 300px
阅读全文
posted @ 2017-04-28 17:04 小小小小小菜鸡程序员
阅读(124)
评论(0)
推荐(0)
数组
摘要: 增:前增(upshift) 作用:在数组前面添加内容 ;返回值:新增后的数组长度,会影响原数组的内容;后增(push) 作用:在数组后面添加内容;返回值:新增后的数组长度,会影响原数组的内容;例子:var arr=[1,2,3,4,5,6];alert(arr.upshift(true,false,
阅读全文
posted @ 2017-04-28 17:03 小小小小小菜鸡程序员
阅读(113)
评论(0)
推荐(0)
原生获取 键盘 keycode 鼠标 键码
摘要: <!DOCTYPE html><html> <head> <meta charset="utf-8"> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <title>原生js数据库测试</title> <link rel="styleshe
阅读全文
posted @ 2017-04-28 17:02 小小小小小菜鸡程序员
阅读(324)
评论(0)
推荐(0)
javascript 拖拽
摘要: <!DOCTYPE html><html lang="en"><head> <meta charset="UTF-8"> <title>拖拽</title> <style> *{ margin: 0; padding: 0; } #div1{ width: 100px; height: 100px;
阅读全文
posted @ 2017-04-28 17:01 小小小小小菜鸡程序员
阅读(88)
评论(0)
推荐(0)
简单的鼠标拖拽
摘要: <!doctype html><html><head> <meta charset="utf-8" /> <title></title> <style type="text/css"> *{margin:0;padding:0;} #box { width: 100px; height: 100px
阅读全文
posted @ 2017-04-28 17:00 小小小小小菜鸡程序员
阅读(112)
评论(0)
推荐(0)
下一页