This file contains hidden or 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 | |
$name = $_GET['name']; | |
header('Content-type:image/png'); | |
echo file_get_contents('/home/ety001/Desktop/'.$name.'.png'); |
This file contains hidden or 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 | |
/** | |
* wechat php test | |
*/ | |
//define your token | |
define("TOKEN", "weixin"); | |
$wechatObj = new wechatCallbackapiTest(); | |
$wechatObj->valid(); |
This file contains hidden or 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 | |
/*------------------------------------------------- | |
| index.php [ 微信公众平台接口 ] | |
+-------------------------------------------------- | |
| Author: LinYunpeng <QQ:50663950> | |
+------------------------------------------------*/ | |
$wechatObj = new wechat(); | |
$wechatObj->responseMsg(); | |
class wechat { |
This file contains hidden or 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 | |
# 甄码农代码 2012 03 06 | |
# 打开sqlite3内存数据库,执行操作,将内存数据库保存到文件 | |
# http://my.oschina.net/u/89296/blog/42717 | |
import sqlite3 | |
import StringIO | |
#使用:memory:标识打开的是内存数据库 | |
con = sqlite3.connect(":memory:") |
This file contains hidden or 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 Person = function(name,age){ | |
this.name = name; | |
this.age = age; | |
} | |
var Print = function(){ | |
this.functionName = 'Print'; | |
this.show = function(){ | |
var msg = []; | |
for(var key in this){ | |
if(typeof(this[key])!='function'){ |
This file contains hidden or 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
[Unit] | |
Description=Shadowsocks Server | |
After=network.target | |
[Service] | |
Type=forking | |
PIDFile=/run/shadowsocks/server.pid | |
PermissionsStartOnly=true | |
ExecStartPre=/bin/mkdir -p /run/shadowsocks | |
ExecStartPre=/bin/chown nobody:nogroup /run/shadowsocks |
This file contains hidden or 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/sh | |
case "$1" in | |
start) | |
/usr/local/bin/ssserver -c /etc/config.json > /dev/null 2>&1 & | |
;; | |
stop) | |
pkill -9 ssserver | |
;; | |
This file contains hidden or 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 app = require('express')(); | |
var bodyParser = require('body-parser'); | |
var multer = require('multer'); | |
//app.use(bodyParser.json()); | |
//app.use(bodyParser.urlencoded({ | |
// extended: true | |
//})); | |
//app.use(multer); | |
app.get('/', function(req, res) { | |
res.send("Hello world!\n"); |
This file contains hidden or 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 _data = { | |
web_title : 'test_web_title', | |
url : 'http%3A%2F%2Fwww.demohour.com%2Fprojects%2F351614', | |
url_hash : '3335cf59a624847a6638ce19c2b98b02', | |
comment_text : '<script>alert(123)</script>' | |
}; | |
写一个算法,遍历_data,生成下面的结果. | |
Result: | |
{ web_title: 'test_web_title' } | |
------- |
This file contains hidden or 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 | |
import sys,os | |
import os.path | |
import xlrd | |
import pypyodbc | |
from datetime import * | |
import time | |
import types | |
OlderNewer