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 zoomIntensity = 0.2; | |
var canvas = document.getElementById("canvas"); | |
var context = canvas.getContext("2d"); | |
var width = 600; | |
var height = 200; | |
var scale = 1; | |
var originx = 0; | |
var originy = 0; |
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
server { | |
listen 8800; | |
server_name '158.182.115.133'; | |
client_max_body_size 10M; | |
location / { | |
proxy_pass_header Server; | |
proxy_set_header Host $http_host; |
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
#!/bin/bash | |
#HOST='http://158.182.151.44' | |
HOST='http://www.ebanshu.com' | |
CLASSROOM_ID=1570 | |
SECTION_ID=4935 | |
FRAME_ID=35107 | |
CONCURRENCY=100 | |
TEST_RESULT_LOG='con_'${CONCURRENCY}'.log' | |
API='/app/api/canvas/frame/detail/?frame_id='${FRAME_ID} | |
if [ x$1 != x ] |
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
Color = { | |
_rgba: function(r, g, b, a) { | |
return { r: r, g: g, b: b, a: a, toString: function() { return "rgba(" + r +", " + g + ", " + b + ", " + a + ")"; } }; | |
}, | |
_hsl: function(h, s, l) { | |
return { h: h, s: s, l: l, toString: function() { return "hsl(" + h +", " + s*100 + "%, " + l*100 + "%)"; } }; | |
}, | |
_hex2Rgba: function(hex) { |
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 TextFind = {}; | |
TextFind.visibleTextNodes = function(container){ | |
var walker = document.createTreeWalker( | |
container, | |
NodeFilter.SHOW_ALL, | |
function(node) { | |
if (node.nodeType == 3) { | |
return NodeFilter.FILTER_ACCEPT; | |
} else if (node.offsetWidth && node.offsetHeight && node.style.visibility != 'hidden') { | |
return NodeFilter.FILTER_SKIP; |
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
{ | |
"name": "imagine", | |
"description": "learning english by reading", | |
"version": "0.0.1", | |
"manifest_version": 2, | |
"app": { | |
"urls": [ | |
"http://17up.org/" | |
], | |
"launch": { |
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
desc "logout" | |
post :logout do | |
Rails.logger.info "----" | |
Rails.logger.info warden | |
warden.logout | |
render_json 0,"ok" | |
end |
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
@media only screen | |
and (min-device-width : 320px) | |
and (max-device-width : 480px) { | |
/* Styles */ | |
} | |
/* Smartphones (landscape) ----------- */ | |
@media only screen | |
and (min-width : 321px) { | |
/* Styles */ |
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
# 跨域请求带上cookie等凭证 | |
$.ajaxSetup | |
xhrFields: | |
withCredentials: true | |
crossDomain: true |
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
phantomjs rasterize.js http://192.168.88.129:9297/\#chart/5 c1.png 1200px |
NewerOlder