后续自己看了下代码,解决方法如下:
修改var/typecho/request.php文件的getUrlPrefix()方法:
public static function getUrlPrefix()
{
if (empty(self::$_urlPrefix)) {
self::$_urlPrefix = (self::isSecure() ? 'https' : 'http')
. '://' . (isset($_SERVER['HTTP_HOST']) ? $_SERVER['HTTP_HOST'] : $_SERVER['SERVER_NAME'])
// . (in_array($_SERVER['SERVER_PORT'], array(80, 443)) ? '' : ':' . $_SERVER['SERVER_PORT']);
;
}
return self::$_urlPrefix;
}
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…