This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* 通过重绘来修复此bug,给位置异常元素添加上.bug_fixed | |
*/ | |
function bug_fixed_for_ie(){ | |
$('.bug_fixed').each(function(i){ | |
this.className = this.className; | |
}); | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE HTML> | |
<html lang="en-US"> | |
<head> | |
<meta charset="UTF-8"> | |
<title>下拉菜单</title> | |
<style type="text/css"> | |
.relative{ | |
position: relative; | |
} | |
.content{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.sl-shadow{ | |
/* modern web browsers */ | |
-moz-box-shadow:1px 3px 12px #bbb; | |
-webkit-box-shadow:1px 3px 12px #bbb; | |
box-shadow:1px 3px 12px #bbb; | |
/* 一定要设置background, 不然 ie 会显示在字体上 */ | |
background: #fff; | |
/* gte=ie8 */ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$('a').click(function(){ | |
var href = $(this).attr("href"); | |
var pos = $(href).offset().top; | |
$("html,body").animate({scrollTop: pos}, 1000); | |
return false; | |
}); | |
// 参考网址 | |
// http://www.zhangxinxu.com/wordpress/2010/07/锚点跳转及jquery下相关操作与插件/ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<style> | |
a:focus{ | |
outline:none; | |
} | |
</style> | |
</head> | |
<body> | |
<a href="#" hidefocus="true" >链接</a> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* 搜索框 */ | |
if( $('.search').length != 0){ | |
var search = $('.search'); | |
var search_enter = $('.search_enter'); | |
search_enter.hide(); | |
search.on({ | |
keyup : function(){ | |
console.log('keyup'); | |
search.val().length != 0 ? search_enter.show() : search_enter.hide(); | |
}, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$(:jqmData(rel='back')).tap(function(e){ | |
$.mobile.back(); | |
return false; | |
}) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.triangle_left, | |
.triangle_down, | |
.triangle_right, | |
.triangle_up{ | |
border:5px dashed transparent; | |
width:0; | |
height:0; | |
font-size:0; | |
overflow:hidden | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Proxifier工具 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* background-attachment: fixed必须有,保证浏览器完整渲染背景图 | |
*/ | |
html { | |
background: url(images/perfect-full-page-bg.jpg) no-repeat center center fixed; | |
-webkit-background-size: cover; | |
-moz-background-size: cover; | |
-o-background-size: cover; | |
background-size: cover; | |
} |