Leser: 14
1 2 3 4 5 6 7 8 9
<?php if ($_SERVER["HTTP_HOST"] == "www.test-one.ru") { header("Location: http://www.test-one/cgi-bin/test1.pl"); } elseif ($_SERVER["HTTP_HOST"] == "www.test-two.ru") { header("Location: ttp://www.test-two/cgi-bin/test2.pl"); } else { header("Location: http://www.test.ru/error.html"); } exit(); ?>