一个文件重定向到此文件,其中包含:
<?
if(!session_id()) {
session_start();
if (strlen($_SESSION['login']) < 1)
die("you're not logged in!");
}
$changer = $_POST['form1'];
switch($changer) {
case 'write':
header("Location: http://teachertechtutor.com/php/learn/kinder/write.php");
break;
case 'read':
header("Location: http://teachertechtutor.com/php/learn/kinder/read.php");
break;
case 'math':
header("Location: http://teachertechtutor.com/php/learn/kinder/math.php");
break;
}
?>
但是当这个重定向时,它会为数学添加一个奇怪的东西: http ://teachertechtutor.com/redirects/kinder.php?math=Math%21
为什么它会添加整个重定向的东西......?redirects/kinder.php?math=Math%21 应该是 php/learn/kinder/math.php