ajax跨域的头部定制

xiaoxiao2021-02-28  115

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

最新回复(0)