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
-module(time_utils). | |
-author("Bearice Ren <[email protected]>"). | |
-export([strftime/2]). | |
strftime(Fmt,{_,_,_}=Time)-> | |
strftime(Fmt,calendar:now_to_datetime(Time)); | |
strftime(Fmt,{_,_}=Time)-> | |
lists:reverse(strftime(str,Fmt,Time,[])). |
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 crypto = require('crypto'); | |
var WSProtocolHandler = { | |
"8":{ | |
handshake:function(req,socket,head,callback){ | |
var key = req.headers["sec-websocket-key"]; | |
if(!key)return false; | |
key += "258EAFA5-E914-47DA-95CA-C5AB0DC85B11"; | |
var sha1 = crypto.createHash('sha1'); | |
sha1.update(key); |
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
/** | |
* jQuery plugin for <del>Dungeon and Dragons</del> Drag and Drop Event | |
*/ | |
(function($){ | |
$.fn.dragAndDropFiles = function(options){ | |
if(typeof(window.FileReader)=== 'undefined')return; | |
var defaults = { | |
MIME : ["image/png","image/jpeg","image/bmp"], | |
//accept = function(e){}, | |
//cancel = function(e){}, |
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
bearice@Bearice-Mac-Air ~ | |
%dig fanfou.icybear.net !693 [20:07:21] | |
; <<>> DiG 9.7.3-P3 <<>> fanfou.icybear.net | |
;; global options: +cmd | |
;; Got answer: | |
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 2591 | |
;; flags: qr rd ra; QUERY: 1, ANSWER: 2, AUTHORITY: 4, ADDITIONAL: 8 | |
;; QUESTION SECTION: |
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
RewriteEngine On | |
RewriteBase / | |
RewriteCond %{HTTP_HOST} !=m.moegirl.org | |
RewriteCond %{HTTP_USER_AGENT} .*iPhone.* [OR] | |
RewriteCond %{HTTP_USER_AGENT} .*Android.* [OR] | |
RewriteCond %{HTTP_USER_AGENT} .*SymbianOS.* [OR] | |
RewriteCond %{HTTP_USER_AGENT} .*Windows\ Phone.* | |
RewriteRule ^(.*)$ http://m.moegirl.org/$1 [L,R=301] |
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
if (obj['replylinks'] !== '') { | |
_ref = obj['replylinks'].split('&'); | |
for (_i = 0, _len = _ref.length; _i < _len; _i++) { | |
x = _ref[_i]; | |
ret.add((x.split('='))[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
<% | |
const L_Title_Text = "IIS - 身份验证管理器" | |
const L_ISM_Text = "Internet 服务管理器" | |
const L_IIS6_Text = "用于 Internet 信息服务器 6.0" | |
const L_PWS_Text = "用于点 Web 服务" | |
const L_PwdSoon_Text = "您的密码将很快过期" | |
const L_ChangePwd_Text = "您想现在更改吗?" | |
const L_SSL1_Text = "要更改密码,需要安全信道(SSL 或 PCT)" | |
const L_SSL2_Text = "您的系统上没有安装或启用 SSL/PCT,请安装,以启用此功能" | |
const L_PasswordExpired_Text = "您的密码已过期" |
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
[ | |
"王", | |
"江", | |
"周", | |
"胡", | |
"刘", | |
"李", | |
"吴", | |
"毛", | |
"温", |
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
%curl 'api.fanfou.com/statuses/user_timeline.json?id=ruif&max_id=khOb6zZ-koQ&count=60&mode=lite' | pjson | grep rawid | sort | |
"rawid": 123828553, | |
"rawid": 123828707, | |
"rawid": 123830009, | |
"rawid": 123832006, | |
"rawid": 123832193, | |
"rawid": 123833721, | |
"rawid": 123833953, | |
"rawid": 123834867, | |
"rawid": 123835062, |
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
export HOST=arm-kindle-linux-gnueabi | |
export CC=$HOST-gcc | |
export CPP=$HOST-g++ | |
export CXX=$HOST-g++ | |
export LD=$HOST-ld | |
export AS=$HOST-as | |
export AR=$HOST-ar | |
export LDFLAGS="-static -static-libgcc -static-libstdc++" | |
export PATH=$PATH:/Volumes/XTools/arm-kindle-linux-gnueabi/bin |
OlderNewer