This file contains 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
.inlineBlock { | |
display: inline-block; | |
*display: inline; | |
*zoom: 1; | |
} |
This file contains 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> | |
<head> | |
<title>jQuery Ajax load</title> | |
<meta charset="utf-8"> | |
</head> | |
<body> | |
<div id="content"> | |
<div id="content-1">最初のコンテンツ1</div> | |
<div id="content-2">最初のコンテンツ2</div> | |
<div id="content-3">最初のコンテンツ3</div> |
This file contains 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
<?php | |
$next_id = $_GET['next_id']; | |
usleep(200000); // 0.2秒スリープ | |
for ($i = $next_id; $i < $next_id + 5; $i++) { | |
if ($i >= 18) { | |
break; | |
} | |
?> |
This file contains 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
var maxHeight = 0; | |
$('.conte').each(function(){ | |
if ( $(this).height() > maxHeight ) { maxHeight = $(this).height(); } | |
}); | |
$('.conte').height(maxHeight); |
This file contains 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
(window.ontouchstart === void 0)? 'click' : 'touchstart'; |
This file contains 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
var timer = false; | |
$(window).resize(function() { | |
if (timer !== false) { | |
clearTimeout(timer); | |
} | |
timer = setTimeout(function() { | |
console.log('resized'); | |
// 処理 | |
}, 200); | |
}); |
This file contains 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
selector-for-YuGothic { | |
font-family:"游ゴシック","YuGothic","ヒラギノ角ゴ ProN","Hiragino Kaku Gothic ProN","Hiragino Kaku Gothic Pro","MS ゴシック",sans-serif; | |
} |
This file contains 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
// 無効 | |
$('#hoge').on('touchmove.noScroll', function(e) { | |
e.preventDefault(); | |
}); | |
// 解除 | |
$('#hoge').off('.noScroll'); |
This file contains 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
$(function() { | |
countDown(); | |
}); | |
function countDown() { | |
var startTime = new Date(), | |
endTime = new Date('March 9,2014, 00:00:00'), | |
diff = endTime - startTime, | |
times = 24 * 60 * 60 * 1000, | |
day = Math.floor(diff / times), |
This file contains 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
function isElement(e) { | |
if (e && e.nodeType === 1) { | |
try { | |
e.nodeType = e.nodeType; | |
} catch(n) { | |
return true; | |
} | |
} | |
return false; | |
} |