您版本的用户数是{\$properties['user']},已经超过该版本的人数限制,请联系我们
email:zentao@cnezsoft.com
电话:4006 889923
网址:www.zentao.net


The number of users is {\$properties['user']} for the edition and has exceeded the limit, please contact us.
email:zentao@cnezsoft.com
tel:4006 889923
Web:www.zentao.net
EOD; $limitUser =<<dao->select("COUNT('*') as count")->from(TABLE_USER)->where('deleted')->eq(0)->fetch(); if(!empty(\$properties) and \$properties['user'] < \$user->count) die("$notice"); EOD; $limitFunc =<<getFileName(); $controlContent = file_get_contents($controlPath); $controlLines = explode("\n", $controlContent); if($controlPath == $fileName) { $endLine = $construct->getEndLine() - 1; $controlLines[$endLine] = $limitUser . "\n" . $controlLines[$endLine]; } else { $methods = $reflection->getMethods(); $startLine = $methods[0]->getStartLine() - 1; $controlLines[$startLine] = $limitFunc . "\n" . $controlLines[$startLine]; } $controlContent = join("\n", $controlLines); file_put_contents($controlPath, $controlContent); } foreach($reflection->getMethods(ReflectionMethod::IS_PUBLIC) as $method) { $methodName = strtolower($method->name); /* This method is not extend from parent */ if($method->getFileName() != $controlPath) continue; if($methodName == '__construct') continue; $params = $method->getParameters(); foreach($params as $param) { $paramName = $param->getName(); if($param->isDefaultValueAvailable()) $defaultValue .= "\$paramDefaultValue['$className']['$methodName']['$paramName'] = '" . $param->getDefaultValue() . "';\n"; } } } /* Set ext control default value.*/ $extControlPath = $module . '/ext/control/'; if(is_dir($extControlPath)) { echo "Seting value for extension of $className\n"; chdir($extControlPath); $extControls = glob($extControlPath . '*'); if(empty($extControls)) continue; foreach($extControls as $extControl) { $methodName = strtolower(substr(basename($extControl), 0, strrpos(basename($extControl), '.'))); $extFile = file_get_contents($extControl); $extLines = explode("\n", $extFile); foreach($extLines as $line) { $line = trim($line); if(preg_match("/^class +($className) +extends +/i", $line, $class) == 1) $extClassName = strtolower($class[1]); if(preg_match("/^class +(my$className) +extends +/i", $line, $class) == 1) $extClassName = strtolower($class[1]); if(preg_match("/^(public)?\s+function\s+$methodName/i", $line) == 1) { $params = strstr($line, '('); if(preg_match('/^(.+)$/', $params) == 0) continue; $params = trim(str_replace(array('(', ')'), '', $params)); $params = preg_replace('/, *\$/', ',\$', $params); $params = explode(',$', trim($params, '$')); foreach($params as $param) { if(strpos($param, '=') === false) continue; $pair = explode('=', $param); $paramName = trim($pair[0]); $paramValue = trim(end($pair)); $defaultValue .= "\$paramDefaultValue['$extClassName']['$methodName']['$paramName'] = $paramValue;\n"; } } } } } } if($defaultValue) { echo "Writing default value to file\n"; $valueFile = "$line) { if(strpos(trim($line), '