* merge framework.
This commit is contained in:
+2
-2
@@ -125,9 +125,9 @@ if(file_exists($myConfig)) include $myConfig;
|
||||
/* 文件上传设置。 Upload settings. */
|
||||
$config->file = new stdclass();
|
||||
// 危险文件类型。 Dangerous file types.
|
||||
$config->file->dangers = ',php,php3,php4,phtml,php5,jsp,py,rb,asp,aspx,ashx,asa,cer,cdx,aspl,shtm,shtml,html,htm,';
|
||||
$config->file->dangers = 'php,php3,php4,phtml,php5,jsp,py,rb,asp,aspx,ashx,asa,cer,cdx,aspl,shtm,shtml,html,htm';
|
||||
// 允许上传的文件类型。 Allowed file types.
|
||||
$config->file->allowed = ',txt,doc,docx,dot,wps,wri,pdf,ppt,xls,xlsx,ett,xlt,xlsm,csv,jpg,jpeg,png,psd,gif,ico,bmp,swf,avi,rmvb,rm,mp3,mp4,3gp,flv,mov,movie,rar,zip,bz,bz2,tar,gz,';
|
||||
$config->file->allowed = 'txt,doc,docx,dot,wps,wri,pdf,ppt,xls,xlsx,ett,xlt,xlsm,csv,jpg,jpeg,png,psd,gif,ico,bmp,swf,avi,rmvb,rm,mp3,mp4,3gp,flv,mov,movie,rar,zip,bz,bz2,tar,gz';
|
||||
|
||||
/* 配置参数过滤。Filter param settings. */
|
||||
/* Like $config->filterParam->param[moduleName][methodname][ruleType] = rule. */
|
||||
|
||||
@@ -1066,7 +1066,8 @@ class baseRouter
|
||||
elseif(isset($_SERVER['REQUEST_URI']))
|
||||
{
|
||||
$value = $_SERVER['REQUEST_URI'];
|
||||
$subpath = '/' . str_replace($_SERVER['DOCUMENT_ROOT'], '', dirname($_SERVER['SCRIPT_FILENAME']));
|
||||
$subpath = str_replace($_SERVER['DOCUMENT_ROOT'], '', dirname($_SERVER['SCRIPT_FILENAME']));
|
||||
if($subpath != '/') $subpath = '/' . $subpath;
|
||||
if($subpath != '' and $subpath != '/' and strpos($value, $subpath) === 0) $value = substr($value, strlen($subpath));
|
||||
}
|
||||
else
|
||||
@@ -2011,10 +2012,6 @@ class baseRouter
|
||||
$view->expiredTime = ini_get('session.gc_maxlifetime');
|
||||
$view->serverTime = time();
|
||||
|
||||
$ip = gethostbyname($_SERVER['HTTP_HOST']);
|
||||
$view->ip = strpos($ip, ':') === false ? $ip : substr($ip, 0, strpos($ip, ':'));
|
||||
$view->name = isset($this->config->socket->name) ? $this->config->socket->name : '';
|
||||
$view->port = isset($this->config->socket->port) ? $this->config->socket->port : '';
|
||||
echo json_encode($view);
|
||||
}
|
||||
|
||||
|
||||
@@ -605,7 +605,8 @@ EOT;
|
||||
global $config;
|
||||
if($config->requestType != 'GET' && method_exists('uri', 'create' . $this->moduleName . $this->methodName))
|
||||
{
|
||||
$link = strip_tags(urldecode($_SERVER['REQUEST_URI']));
|
||||
$link = strip_tags(urldecode($_SERVER['REQUEST_URI']));
|
||||
$link = htmlspecialchars($link,ENT_QUOTES);
|
||||
|
||||
if($this->params['pageID'] == 1) return html::a(preg_replace('/\/p\d+\./', '.', $link), $title);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user