Posted by Frits van Leeuwen on 10/03/06 09:58
"Frits van Leeuwen" <Frits.vanLeeuwen@nospam.nl> schreef in bericht
news:c1c28$45220777$c2ab6db8$18457@news1.tudelft.nl...
> > Links:
> > Flag En: <a href="/language.php?ln=en">English</a>
> > Flag Du: <a href="/language.php?ln=du">Dutch</a>
> >
> > In all headers on index, etc.
> >
> > <?
> > switch ($_COOKIE[LeeuwendeelTaal]))
> > {
> > case 'en':
> > // LOAD ENGLISH
> > break;
> > case 'du':
> > // LOAD DUTCH
> > break;
> > default:
> > // LOAD ENGLISH
> > break;
> >
> > ?>
> >
> > // Cookie page: language.php
> > <?
> > unset($_COOKIE[LeeuwendeelTaal]);
> > switch ($_GET[ln])
> > {
> > case 'en':
> > $language = "en";
> > break;
> > case 'du':
> > $language = "du";
> > break;
> > default:
> > $language = "en";
> > break;
> > }
> > setcookie("LeeuwendeelTaal", $language, time()+360000);
> > header("Location: index.php");
> > header("Connection: close");
> > exit;
> > ?>
> >
> I'll give it a try.
> with //LOAD ... do you mean a html page in one of the languages?
>
When I use header("Location: index.php"); the cookie will be not set.
What's wrong?
Navigation:
[Reply to this message]
|