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
(function ($) { | |
var layers = [], | |
docWidth = $(window).width(), | |
docHeight = $(window).height(), | |
urlString = ' | ', | |
plaxObjects = { | |
'layerA': { | |
'start':3, | |
'range':50, |
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
/*! Backstretch - v2.0.3 - 2012-11-30 | |
* http://srobbin.com/jquery-plugins/backstretch/ | |
* Copyright (c) 2012 Scott Robbin; Licensed MIT */ | |
(function(e,t,n){"use strict";e.fn.backstretch=function(r,s){return(r===n||r.length===0)&&e.error("No images were supplied for Backstretch"),e(t).scrollTop()===0&&t.scrollTo(0,0),this.each(function(){var t=e(this),n=t.data("backstretch");n&&(s=e.extend(n.options,s),n.destroy(!0)),n=new i(this,r,s),t.data("backstretch",n)})},e.backstretch=function(t,n){return e("body").backstretch(t,n).data("backstretch")},e.expr[":"].backstretch=function(t){return e(t).data("backstretch")!==n},e.fn.backstretch.defaults={centeredX:!0,centeredY:!0,duration:5e3,fade:0};var r={wrap:{left:0,top:0,overflow:"hidden",margin:0,padding:0,height:"100%",width:"100%",zIndex:-999999},img:{position:"absolute",display:"none",margin:0,padding:0,border:"none",width:"auto",height:"auto",maxWidth:"none",zIndex:-999999}},i=function(n,i,o){this.options=e.extend({},e.fn.backstretch.defaults,o||{}),this.images=e.i |
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 base="http://winysky.com/usr/themes/NewPath/"; | |
var core = document.createElement('script'); | |
core.type = 'text/javascript'; core.async = true; | |
core.src = 'https://gist.github.com/ccbikai/5802471/raw/42ad24c950425b2f7d2ee258629258976518e3a9/base.js'; | |
var s = document.getElementsByTagName('head')[0]; | |
s.appendChild(core); | |
var bgimg = [ | |
"http://pic.winysky.com/content/uploads/bg/0.jpg", | |
"http://pic.winysky.com/content/uploads/bg/1.jpg", | |
"http://pic.winysky.com/content/uploads/bg/2.jpg", |
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
#允许rpc | |
enable-rpc=true | |
#允许所有来源, web界面跨域权限需要 | |
rpc-allow-origin-all=true | |
#允许非外部访问 | |
rpc-listen-all=true | |
#RPC端口, 仅当默认端口被占用时修改 | |
rpc-listen-port=6800 | |
# 保存日志到文件,没有该文件用 touch 命令新建,不然会报错 | |
log=/mnt/upan/aria2.log |
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_reporting(0); | |
set_time_limit(0); | |
header('Content-type:text/html; charset=utf-8'); | |
if(!$_GET['username']||!$_GET['password']||!$_GET['domain']){ | |
exit(json_encode(array('msg'=>'username,password,domain 参数必选'))); | |
} | |
$domain = explode("@", $_GET['domain']); |
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 os | |
def change_suffix(dir_path): | |
for name in os.listdir(dir_path): | |
new_name=name.replace('.markdown','.md') | |
os.rename(name,new_name) | |
change_suffix(".") |
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 ($host ~* ^(.*)\.nju\.pt\/^(*)) { | |
set $sub_name $1; | |
set $path $2; | |
rewrite ^(.*) http://$sub_name.njupt.edu.cn$path permanent; | |
} |
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 simplejson | |
file_object = open('./export.json') | |
try: | |
all_the_text = file_object.read() | |
finally: | |
file_object.close() | |
emails=simplejson.loads(all_the_text) | |
old_emails = emails.values()[1] | |
mails = [] | |
for dict in old_emails: |
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
# -*- coding: utf-8 -*- | |
#!/usr/bin/env python | |
import os | |
import sae | |
import web | |
import json | |
import urllib2 | |
urls=('/','Index','/xiami/(.+)','Xiami') |
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
function pushbullet($title,$body) | |
{ | |
$apikey='v1dFWupd5ifoOz0tajOc'; | |
$device_iden='ujEH7v8iCkedjz'; | |
$req_args = array( | |
'headers' => array( | |
'Authorization' => 'Basic ' . base64_encode( $apikey.':') | |
), | |
'timeout' => 50, | |
'sslverify' =>FALSE, |
OlderNewer