【发布时间】:2015-03-12 06:16:01
【问题描述】:
我有一个函数skipCopy:
public function skipCopy($skipcopy){
$skipcopy1 = $skipcopy;
}
现在我希望在 copy() 函数中使用 $skipcopy1 中的值,结构如下:
protected function copy($id, $srcip, $srcusername, $srcpassword, $tgtip, $tgtusername, $tgtpassword, $publish) {
//use $skipcopy1 here. Do this without passing the value as parameter. as all the parameters in the copy function are mandatory.
}
我怎样才能做到这一点。
这两个函数属于同一个 PHP 类。
【问题讨论】: