Det nemmeste er jo nok at gøre: (et eksempel fra php.net)
<?php
// set the cookies
setcookie("cookie[three]", "cookiethree");
setcookie("cookie[two]", "cookietwo");
setcookie("cookie[one]", "cookieone");
// after the page reloads, print them out
if (isset($_COOKIE['cookie'])) {
foreach ($_COOKIE['cookie'] as $name => $value) {
$name = htmlspecialchars($name);
$value = htmlspecialchars($value);
echo "$name : $value <br />\n";
}
}
?>
Rettelse:http://www.php.net/manual/en/function.setcookie.php
Indlæg senest redigeret d. 21.04.2011 19:51 af Bruger #7728