ajax实现跨域的头部设置
public function
_initialize() {
header(
"Content-Type:text/html; charset=utf-8");
header(
'Content-Type:application/json; charset=utf-8');
header(
"Access-Control-Allow-Origin: *");
//
$systemConfig = include
'./application/Common/Conf/systemConfig.php';
$this->url = C(
'IMG_PREFIX');
$text=
"\n\n".date(
"y-m-d H:i:s",time()).
"\n".
$_SERVER[
"QUERY_STRING"].
"\rpost:\r".var_
export(
$_POST,
true).
"\rget:\r".var_
export(
$_GET,
true).
"\rfile:\r".var_
export(
$_FILES,
true);
file_put_contents(
"logo.txt",
$text, FILE_APPEND);
//
$this->assign(
"site",
$systemConfig);
}
转载请注明原文地址: https://www.6miu.com/read-44914.html