Skip to content

Instantly share code, notes, and snippets.

View roseforyou's full-sized avatar
🎯
Focusing

AZu roseforyou

🎯
Focusing
View GitHub Profile
@roseforyou
roseforyou / getURLparams.js
Last active August 29, 2015 13:56
get URL parameters, key and value
//URL: http://www.example.com/?var1=val1&var2=val2=val3&test=3&test=43&aaa=#2
//window.location.search will return "?var1=val1&var2=val2=val3&test=3&test=43&aaa="
//use the location.search, because # could be remove.
//refer:
//https://gist.github.com/alkos333/1771618
//http://papermashup.com/read-url-get-variables-withjavascript/
//http://jquery-howto.blogspot.com/2009/09/get-url-parameters-values-with-jquery.html
<!DOCTYPE html>
<html>
<head>
<script src="http://code.jquery.com/jquery-1.9.1.min.js"></script>
<script src="http://sole.github.io/tween.js/build/tween.min.js"></script>
<meta charset="utf-8">
<title>JS Bin</title>
<style>
#target{
width:50px;
<!DOCTYPE html>
<html>
<head>
<script src="http://code.jquery.com/jquery-1.9.1.min.js"></script>
<script src="http://sole.github.io/tween.js/build/tween.min.js"></script>
<script src="http://sole.github.io/tween.js/examples/js/RequestAnimationFrame.js"></script>
<meta charset="utf-8">
<title>JS Bin</title>
</head>
//中央球场列表
$('.football_bg').removeClass('football_bg').css({
width: '93px',
height: '106px',
position: 'absolute',
left: '14px',
top: '27px',
'font-size': '12px'
}).show();
$('.football_bg2').removeClass('football_bg2').css({
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>world cup</title>
<script src="http://code.jquery.com/jquery-1.9.1.min.js"></script>
<script src="http://underscorejs.org/underscore-min.js"></script>
<style id="jsbin-css">
body{
font: 12px 微软雅黑,tahoma,arial;
@roseforyou
roseforyou / index.html
Last active August 29, 2015 14:05
world cup// source http://jsbin.com
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>world cup</title>
<script src="http://code.jquery.com/jquery-1.9.1.min.js"></script>
<script src="http://underscorejs.org/underscore-min.js"></script>
<style id="jsbin-css">
body{
font: 12px 微软雅黑,tahoma,arial;
@roseforyou
roseforyou / index.html
Created July 17, 2015 09:12 — forked from anonymous/index.html
canvas 二次方贝赛尔曲线 打点
<!DOCTYPE html>
<html>
<head>
<script src="https://code.jquery.com/jquery-1.9.1.min.js"></script>
<meta charset="utf-8">
<title>JS Bin</title>
</head>
<script>
function quadraticBzier(p, p0, p1, p2){
return Math.pow(1-p,2)*p0 +2*p*(1-p)*p1+Math.pow(p,2)*p2;
@roseforyou
roseforyou / jsbin.AlULIxi.html
Created December 17, 2013 01:33
jQuery div drag demo. demo Url: jsbin.com/AlULIxi/1000
<!DOCTYPE html>
<html>
<head>
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js"></script>
<meta charset=utf-8 />
<style>
body{
margin:0;
padding:0;
}
body {
padding:0;
margin:0;
}
#block {
width:50px;
height:50px;
background-color:red;
position:absolute;
top: 100px;
@roseforyou
roseforyou / jsbin.axoJoHo.html
Last active January 1, 2016 17:49
MBSJ Login Page
<!DOCTYPE html>
<html>
<head>
<meta name="description" content="MBSJ Login Page" />
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.8/jquery.min.js"></script>
<meta charset=utf-8 />
<title>Login Page</title>
</head>
<body>
<form action="#" id="_js_form">