phpbar.de logo

Mailinglisten-Archive

Re: [php] php redirector ?
Archiv Mailingliste php_(at)_infosoc.uni-koeln.de

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [php] php redirector ?



Hi Alexander,

in einer extrem simplen Version geht das so:
<?
mysql_connect($hostname, $username, $password) or die("Unable to connect to
database");
_(at)_mysql_select_db("$dbname") or die("Unable to select database");
$query="SELECT url FROM banners WHERE id=$id";
$result=mysql_query($query);
$data=mysql_fetch_row($result);
$url=$data[0];
header("Location: $url");
?>

und dann z.B. mit 'redirect.php3?id=13' aufrufen...

Gre
Stephan

http://analogon.com/php/





Home | Main Index | Thread Index

php::bar PHP Wiki   -   Listenarchive