标签:encode ret serve session pre request reac 存储 原因
1、初始化管理员密码失败原因1: 存储满;
原因2: 较早版本的一个BUG,当改变默认Web端口后,调用的接口位置错误:
见: libs/InterfaceClient.php
private static function packUrl($controller,$request,$paras=null){
$token = NSession::get("token");
$url = self::SERVER_URL . $controller . "/?request=$request";
if($token!=""){
$url .= "&token=$token";
}
if($paras){
if(is_array($paras)){
foreach ($paras as $key=>$value){
$url .= "&$key=" . urlencode($value);
}
}else{
$url .= "&$paras";
}
}
return $url;
}
改为:
private static function packUrl($controller,$request,$paras=null){
$token = NSession::get("token");
//$url = self::SERVER_URL . $controller . "/?request=$request";
$url = "http://127.0.0.1";
$port = $_SERVER[‘SERVER_PORT‘];
if($port!=80){
$url.= ":" . $port;
}
$url .= "/mserver/interface/";
$url .= $controller . "/?request=$request";
if($token!=""){
$url .= "&token=$token";
}
if($paras){
if(is_array($paras)){
foreach ($paras as $key=>$value){
$url .= "&$key=" . urlencode($value);
}
}else{
$url .= "&$paras";
}
}
return $url;
}
标签:encode ret serve session pre request reac 存储 原因
原文地址:http://blog.51cto.com/livestreaming/2307253