PHP Class UpgradeAction, thinksns

Inheritance: extends Action
Show file Open project: medz/thinksns-4

Public Methods

Method Description
_initialize ( ) 执行前
ajxjCheck ( ) 后台检测
check ( ) 检查是否有更新
showMessage ( string $message, string $type, string $url = false, integer $s = 3 ) 显示消息
step1 ( ) 升级程序第一步 下载增量包
step2 ( ) 升级程序第二步 - 执行文件替换
step3 ( ) 升级第三步 - 删除升级标记需要删除的文件 和执行sql文件

Protected Methods

Method Description
rm ( string $path, boolean $recursive = true ) : boolean 删除函数,自带递归

Private Methods

Method Description
showError ( string $message = '', string $defaultMessage = '错误' ) 显示错误消息
showSuccess ( string $message = '', string $defaultMessage = '正确' ) 显示正确消息
showUpgrade ( $log, $downUrl ) 显示升级信息

Method Details

_initialize() public method

执行前
Author: Medz Seven ([email protected])
public _initialize ( )

ajxjCheck() public method

后台检测
Author: Medz Seven ([email protected])
public ajxjCheck ( )

check() public method

检查是否有更新
Author: Medz Seven ([email protected])
public check ( )

rm() protected method

删除函数,自带递归
Author: Medz Seven ([email protected])
protected rm ( string $path, boolean $recursive = true ) : boolean
$path string 删除的地址
$recursive boolean 是否递归 [true]
return boolean

showMessage() public method

显示消息
Author: Medz Seven ([email protected])
public showMessage ( string $message, string $type, string $url = false, integer $s = 3 )
$message string 消息
$type string [success|error] 消息类型
$url string 跳转的url
$s integer 等待的时间

step1() public method

升级程序第一步 下载增量包
Author: Medz Seven ([email protected])
public step1 ( )

step2() public method

升级程序第二步 - 执行文件替换
Author: Medz Seven ([email protected])
public step2 ( )

step3() public method

升级第三步 - 删除升级标记需要删除的文件 和执行sql文件
Author: Medz Seven ([email protected])
public step3 ( )