Query tickets in china
- Copy ticket.js and run it on your browser
- Install node.js
- Put package.json and server.js into a folder
- Copy a mp3 to the same forder and rename it to "alert.mp3"
.fake_file_input { | |
background: url(../images/fake_file_input.png) no-repeat; | |
cursor: pointer; | |
width: 150px; | |
height: 30px; | |
overflow: hidden; | |
position: relative; | |
display: inline-block; | |
*display: inline; | |
*zoom: 1; |
(* | |
Copyright (c) 2008, Christian Mittendorf <[email protected]> | |
All rights reserved. | |
Redistribution and use in source and binary forms, with or without | |
modification, are permitted provided that the following conditions are met: | |
Redistributions of source code must retain the above copyright notice, this | |
list ofconditions and the following disclaimer. Redistributions in binary form | |
must reproduce the above copyright notice, this list of conditions and the |
var time = (+new Date) + 1000 * 60; | |
process.nextTick(function w(){ | |
if(+new Date < time) | |
process.nextTick(arguments.callee) | |
}); |
Query tickets in china
<?php | |
$size = pow(2, 16); // 16 is just an example, could also be 15 or 17 | |
$startTime = microtime(true); | |
$array = array(); | |
for ($key = 0, $maxKey = ($size - 1) * $size; $key <= $maxKey; $key += $size) { | |
$array[$key] = 0; | |
} |
//test browser "look-before-you-leap" (LBYL) request | |
//expect is a header of HTTP/1.1 | |
var http = require('http'); | |
http.createServer(function(req,res){ | |
console.log(req.header['user-agent'],req.header.expect); | |
}); |
#Escape the 1.4GB V8 heap limit patch for Version 3.10.2 | |
Usage: patch -p0 < v8.patch |
打开 Preferences -> Terminal 保证:Accept ramte connectio 选中。 | |
mate ~/.ssh/config | |
添加下面: | |
Host * | |
RemoteForward 52698 127.0.0.1:52698 | |
登录远程的一台 linux 机器。运行下面的命令: |
Practice BFN with nodebnf parse codekit "@codekit-prepend,@codekit-append" expression. see http://incident57.com/codekit/help.php#help-imports-warning
#!/usr/bin/env node | |
//please requist your app token from | |
//https://trello.com/1/connect?key=yourkey&name=git-hook&expiration=never&response_type=token&scope=read,write | |
var key = "your key"; | |
var token = "your token"; | |
//https://trello.com/board/-/4e9003324a517dad44465056 | |
var board_id = "4e9003324a517dad44465056"; | |
var Trello = require("node-trello"); |