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
/** | |
* @fileOverview Show a qrcode image on browser lower right | left corner | |
* @author ra <[email protected]> | |
* @version 0.0.1 | |
* @see {@link http://usejsdoc.org|jsdoc} | |
* | |
* | |
* @example | |
* | |
* qrsource:{ |
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
/** | |
* @fileOverview Javascript high precision calculate | |
* @author ra <[email protected]> | |
* @version 0.1 | |
* @see {@link http://usejsdoc.org|jsdoc} | |
* @example | |
* | |
* 0.05 + 0.01 //0.060000000000000005 | |
* 1.0 - 0.42 //0.5800000000000001 | |
* 4.015 * 100 //401.49999999999994 |
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
/** | |
* @fileOverview Hexdump util | |
* @author ra <[email protected]> | |
* @version 0.0.1 | |
* @see {@link http://usejsdoc.org|jsdoc} | |
* @example | |
* var stuff="30313233343536";// "0123456" | |
* var retval=hexdump.pretty(hexdump.decode(stuff)); | |
* console.log(retval); | |
* |
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
/** | |
*@fileOverview JavaScript utils | |
*@author ra <[email protected]> | |
*@version 0.0.1 | |
*@see {@link http://usejsdoc.org|jsdoc} | |
*@example | |
* | |
* var currency=comm.formatCurrency(123456); | |
* //output | |
* '123, 456.00' |
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
<html> | |
<head> | |
<title>The page is temporarily unavailable</title> | |
<style> | |
body { font-family: Tahoma, Verdana, Arial, sans-serif; } | |
</style> | |
</head> | |
<body bgcolor="white" text="black"> | |
<table width="100%" height="100%"> | |
<tr> |
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 _cdrun = { | |
seconds:120, | |
ok:true, | |
ui: function(){ | |
if(_cdrun.seconds>=0){ | |
__smsId.innerHTML="("+_cdrun.seconds+")秒后重新发送"; | |
__smsId.style.color="gray"; | |
__mobileId.disabled=true; | |
_cdrun.seconds--; | |
_cdrun.ok=false; |
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
#! /usr/bin/env bash | |
# | |
# Control unicorn server | |
# | |
# NOTICE: | |
# Environment -> production | |
# | |
# Author: Tony | |
# |
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
# Set the working application directory | |
work_path=ENV["WORK_PATH"] | |
# App path (current dir) | |
app_path=`pwd`.gsub "\n", "" | |
puts "work_path: #{work_path}" | |
puts "app_path: #{app_path}" | |
# working_directory "/path/to/your/app" | |
working_directory app_path | |
# Unicorn PID file location | |
# pid "/path/to/pids/unicorn.pid" |
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
/** | |
* Return phone number type | |
* <p>For china:</p> | |
* <ul> | |
* <li>0 unknow</li> | |
* <li>1 china mobile (cellphone)</li> | |
* <li>2 china unicom (cellphone)</li> | |
* <li>3 china net (cellphone)</li> | |
* <li>4 china net (telphone)</li> |
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
#! /usr/bin/env bash | |
arg1=$1 | |
arg2=$2 | |
arg3=$3 | |
FILTER=${arg1:-*} | |
PREFIX=${arg2:-n} | |
SUFFIX=${arg3:-.n} |
OlderNewer