cookie

Gestart doorOne2xs6 reacties28 weergaven

7 berichten · pagina 1 van 1

One2xs

Bot · Topicstarter

Berichten
93.699
Reputatie
0
Punten
1,27
Lid sinds
Laatst gezien
ik probeer een cookie te maken maar dat werkt niet:

[COLOR= #0000BB]<?php[/COLOR]
[URL="http://www.php.net/session_start"]session_start[/URL][COLOR= #007700]();[/COLOR]
[URL="http://www.php.net/ob_start"]ob_start[/URL][COLOR= #007700]();[/COLOR]
[URL="http://www.php.net/define"]define[/URL][COLOR= #007700]([/COLOR]URL[COLOR= #007700],[/COLOR][COLOR= #DD0000]http://localhost/bestanden/PF/[/COLOR][COLOR= #007700]);[/COLOR]
[URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][URL="http://www.php.net/isset"]isset[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_GET[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]lang[/COLOR][COLOR= #007700]])){[/COLOR]
    [URL="http://www.php.net/setcookie"]setcookie[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]lang[/COLOR][COLOR= #007700],[/COLOR][COLOR= #0000BB]$_COOKIE[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]lang[/COLOR][COLOR= #007700]],[/COLOR][URL="http://www.php.net/time"]time[/URL][COLOR= #007700]()-[/COLOR][COLOR= #0000BB]999[/COLOR][COLOR= #007700]);[/COLOR]
    [URL="http://www.php.net/setcookie"]setcookie[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]lang[/COLOR][COLOR= #007700],[/COLOR][COLOR= #0000BB]$_GET[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]lang[/COLOR][COLOR= #007700]],[/COLOR][COLOR= #DD0000]9999999999999999999999999[/COLOR][COLOR= #007700]);[/COLOR]
    [URL="http://www.php.net/header"]header[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"location: "[/COLOR][COLOR= #007700].[/COLOR]URL[COLOR= #007700].[/COLOR][COLOR= #DD0000]"p/home"[/COLOR][COLOR= #007700]);
}[/COLOR]
?>


de bedoeling is dat er EN of NL wordt ingevuld:

<td><img src="[COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/echo"]echo[/URL] URL ?>images/nl.gif" lang="nl" onclick="document.location = [COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/echo"]echo[/URL] URL ?>lang?lang=NL" /></td>
        <td><img src="[COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/echo"]echo[/URL] URL ?>images/en.gif" lang="en" onclick="document.location = [COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/echo"]echo[/URL] URL ?>lang?lang=EN" /></td>


en ik roep het gewoon aan met:

[COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/echo"]echo[/URL] [COLOR= #0000BB]$_COOKIE[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]lang[/COLOR][COLOR= #007700]];[/COLOR] ?>


en het blijft NL
hoe zorg ik ervoor dat EN gewoon werkt enzo?
0
Berichten
18.482
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
Je probeert een cookie te maken die ergens in het verleden afloopt emoVerander - in +
0
One2xs

Bot · Topicstarter

Berichten
93.699
Reputatie
0
Punten
1,27
Lid sinds
Laatst gezien
[COLOR= #0000BB]<?php[/COLOR]
[URL="http://www.php.net/session_start"]session_start[/URL][COLOR= #007700]();[/COLOR]
[URL="http://www.php.net/ob_start"]ob_start[/URL][COLOR= #007700]();[/COLOR]
[URL="http://www.php.net/define"]define[/URL][COLOR= #007700]([/COLOR]URL[COLOR= #007700],[/COLOR][COLOR= #DD0000]http://localhost/bestanden/PF/[/COLOR][COLOR= #007700]);[/COLOR]
[URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][URL="http://www.php.net/isset"]isset[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_GET[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]lang[/COLOR][COLOR= #007700]])){[/COLOR]
    [URL="http://www.php.net/setcookie"]setcookie[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]lang[/COLOR][COLOR= #007700],[/COLOR][COLOR= #0000BB]$_COOKIE[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]lang[/COLOR][COLOR= #007700]],[/COLOR][URL="http://www.php.net/time"]time[/URL][COLOR= #007700]()+[/COLOR][COLOR= #0000BB]999[/COLOR][COLOR= #007700]);[/COLOR]
    [URL="http://www.php.net/setcookie"]setcookie[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]lang[/COLOR][COLOR= #007700],[/COLOR][COLOR= #0000BB]$_GET[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]lang[/COLOR][COLOR= #007700]],[/COLOR][COLOR= #DD0000]9999999999999999999999999[/COLOR][COLOR= #007700],[/COLOR][COLOR= #DD0000]/[/COLOR][COLOR= #007700]);[/COLOR]
    [URL="http://www.php.net/header"]header[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"location: "[/COLOR][COLOR= #007700].[/COLOR]URL[COLOR= #007700].[/COLOR][COLOR= #DD0000]"p/home"[/COLOR][COLOR= #007700]);
}[/COLOR]
?>


Werkt nog niet emo?

Want de eerste is om hem te deleten en de 2de om te maken
0
Berichten
18.482
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
[COLOR= #0000BB]<?php[/COLOR]
[URL="http://www.php.net/session_start"]session_start[/URL][COLOR= #007700]();[/COLOR]
[URL="http://www.php.net/ob_start"]ob_start[/URL][COLOR= #007700]();[/COLOR]
[URL="http://www.php.net/define"]define[/URL][COLOR= #007700]([/COLOR]URL[COLOR= #007700],[/COLOR][COLOR= #DD0000]http://localhost/bestanden/PF/[/COLOR][COLOR= #007700]);[/COLOR]
[URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][URL="http://www.php.net/isset"]isset[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_GET[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]lang[/COLOR][COLOR= #007700]])){[/COLOR]
    [URL="http://www.php.net/setcookie"]setcookie[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]lang[/COLOR][COLOR= #007700],[/COLOR][COLOR= #0000BB]$_GET[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]lang[/COLOR][COLOR= #007700]],[/COLOR] [URL="http://www.php.net/time"]time[/URL][COLOR= #007700]() +[/COLOR] [COLOR= #0000BB]60[/COLOR][COLOR= #007700]*[/COLOR][COLOR= #0000BB]60[/COLOR][COLOR= #007700]*[/COLOR][COLOR= #0000BB]24[/COLOR][COLOR= #007700]*[/COLOR][COLOR= #0000BB]7[/COLOR][COLOR= #007700]*[/COLOR][COLOR= #0000BB]100[/COLOR][COLOR= #007700],[/COLOR][COLOR= #DD0000]/[/COLOR][COLOR= #007700]);[/COLOR]
    [URL="http://www.php.net/header"]header[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"location: "[/COLOR][COLOR= #007700].[/COLOR]URL[COLOR= #007700].[/COLOR][COLOR= #DD0000]"p/home"[/COLOR][COLOR= #007700]);
}[/COLOR]
?>
0
One2xs

Bot · Topicstarter

Berichten
93.699
Reputatie
0
Punten
1,27
Lid sinds
Laatst gezien
nog steeds werkt niet sadleyEDIT:
weet al
er waren 2 cookies en een had de pad van alleen die map
nu werkt het biggrin@luuk
hoelang is die geldig?
0
Berichten
18.482
Reputatie
0
Punten
0,00
Lid sinds
Laatst gezien
700 dagen als het goed is
0
One2xs

Bot · Topicstarter

Berichten
93.699
Reputatie
0
Punten
1,27
Lid sinds
Laatst gezien
ok
0

Jouw reactie

Deel je idee, stel een vraag of help een ander verder.

Editor laden…

Praat mee met de One2xs-community.

Inloggen om te reageren