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
/* | |
12306 Auto Login => A javascript snippet to help you auto login 12306.com. | |
Copyright (C) 2011 Kevintop | |
Includes jQuery | |
Copyright 2011, John Resig | |
Dual licensed under the MIT or GPL Version 2 licenses. | |
http://jquery.org/license | |
Includes 12306.user.js |
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
| |
-- | |
-- 表的结构 `area` | |
-- | |
DROP TABLE IF EXISTS `area`; | |
CREATE TABLE IF NOT EXISTS `area` ( | |
`id` int(11) NOT NULL auto_increment, | |
`areaID` int(11) NOT NULL, | |
`area` varchar(20) character set gbk NOT NULL, |
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
#!/usr/bin/env python | |
# coding: utf-8 | |
'''用Python脚本查询纯真IP库 | |
增强traceroute | |
traceroute app.yinxiang.com | awk -F"[()]" '{if($2~/[0-9\.]./){printf("%s |",$0);system("python cip.py "$2);}else{print $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
<?php | |
//forward('3514498319000665', '转发'); | |
function add($text){ | |
$params = array( | |
'text'=>$text, | |
'rank'=>0, | |
'location'=>'home', | |
'module'=>'stissue', |
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 | |
error_log("============\n".date('Y-m-d H:i')."\n", 3, 'logs/yunpan.log'); | |
$cookie = '你的cookie,去掉token'; | |
function get_token($cookie, $url = 'http://c4.yunpan.360.cn/user/login?st=449'){ | |
$ch = curl_init(); | |
curl_setopt_array($ch, array( | |
CURLOPT_COOKIE => $cookie, | |
CURLOPT_HTTPGET => true, | |
CURLOPT_HEADER => 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
<?php | |
$prefix = "-----BEGIN PUBLIC KEY-----\n"; | |
$surfix = '-----END PUBLIC KEY-----'; | |
$key = "your google play pub key"; | |
$key =$prefix . chunk_split($key, 64, "\n") . $surfix; | |
$key = openssl_get_publickey($key); | |
if (false === $key) { | |
echo "invalid public key\n"; | |
return; |
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
//数独 | |
import java.util.*; | |
public class Sudoku{ | |
private static int steps=0; | |
private static int sudo[][]=new int[][]{ | |
{0,0,0,0,0,9,6,0,0}, | |
{0,0,7,0,0,1,0,0,0}, | |
{0,4,0,0,0,0,0,0,0}, | |
{0,0,0,0,4,0,0,0,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
//decode result with dc command like dc -e0000P | |
import java.math.BigInteger; | |
public class DC_encode { | |
public static void main(String[] args) { | |
String a=""; | |
String b=args[0]+"\n"; | |
for(int i=0;i<b.length();i++){ | |
if(Integer.toBinaryString(b.charAt(i)).length()==8) | |
a=a+Integer.toBinaryString(b.charAt(i)); | |
else{ |
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 | |
// https://github.com/fuchaoqun/colaphp/blob/2.0/Cola/Ext/GoogleAuthenticator.php | |
class Cola_Ext_GoogleAuthenticator | |
{ | |
public static $ttl = 30; | |
public static $limit = 6; | |
// Lookup needed for Base32 encoding | |
private static $map = array( |
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
# encoding: utf-8 | |
require 'rubygems' | |
require 'haml' | |
require 'erb' | |
require 'erubis' | |
notes = [] | |
20.times { notes << {:title => "标题标题", :content => "内容,内容"} } | |
obj = { |
OlderNewer