我在这里偶然发现了这个PHP URL Rotator脚本(http://motiongroove.com/2010/03/03/free-php-url-rotator-script/),但是由于某种原因,这个该死的东西总是给我这个错误:
致命错误:在第4行调用/servername/index.php中未定义的函数sset()
这是我收到的代码:
<?php $link[1] = "http://yourdomain.com/index1.html";
$link[2] = "http://yourdomain.com/index2.html";
$link[3] = "http://yourdomain.com/index3.html";
if(!sset($HTTP_cookie_VARS['link'])){ $n=count($link);
$rand=rand(1,$n); setcookie("link",$rand,time()+3600);
header('location:'.$link[$rand]); }else{ $go=$link[$_COOKIE['link']]; header('location:'.$go); } ?>谢谢!
发布于 2010-09-29 13:20:41
应该是isset(),而不是sset()
这就是:
if(!isset($HTTP_COOKIE_VARS['link']))在第四行的开头。
我相信COOKIE在$HTTP_COOKIE_VARS中必须是大写的。
https://stackoverflow.com/questions/3818908
复制相似问题