警告:标头不能包含多个标头,在第 16 行的********.php**

  • 本文关键字:行的 php 在第 不能 包含多 警告 php
  • 更新时间 :
  • 英文 :


>怎么了?! 第 16 行是:header('Location: '.$get_link.''(;

<?php
require_once("../libs/proxy.php");
require_once("../libs/config.php");
require_once("../libs/ip.php");
$rnd = intval(rand(1000,9999)); //generate random number
$lnk_lnk = "../$db_name/lnk/$userip.xxx"; //link path
$api_url = "http://btc.ms/?api=$btcms_api&url=$site_url/links/verifier.php? 
id=$rnd&format=text";
$get_link = file_get_contents($api_url);
if (!empty($get_link)) {
$m_lnk = fopen($lnk_lnk, "w"); //open link file
fwrite($m_lnk, $rnd); //store random value
fclose($m_lnk);
header('Location: '.$get_link.''); //here is line 16!
} else {
header("Location: ../index.php?lnkmsg=Unknown Error.");
}
?>

感谢您的帮助! . . . . . . . . . . .

也许您的网址包含多行。您可以使用函数urlencode()来更正此错误。

试试这个,

header('Location: '.urlencode($get_link)); //here is line 16!

最新更新