/[cvs]/bareface/yakka/library/YakkaCookieHandler.php
ViewVC logotype

Contents of /bareface/yakka/library/YakkaCookieHandler.php

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.1 - (show annotations)
Sun Jan 5 00:22:25 2003 UTC (22 years ago) by bareface
Branch: MAIN
CVS Tags: HEAD
init;

1 <?php
2
3 ini_set("session.use_cookies", "0");
4
5 class YakkaCookieHandler {
6 var $name;
7 var $ticket;
8
9 function YakkaCookieHandler($name = null) {
10 if (!$name)
11 $this->name = "YakkaCookie";
12 else
13 $this->name = $name;
14
15 global $HTTP_COOKIE_VARS;
16
17 if ($HTTP_COOKIE_VARS[$this->name])
18 $this->ticket = $HTTP_COOKIE_VARS[$this->name];
19 else
20 $this->ticket = null;
21 }
22
23 function clearCookie() {
24 setcookie($this->name, "", 1, "/");
25 }
26
27 function &loadCookie() {
28 return $this->ticket;
29 }
30
31 function saveCookie() {
32 global $HTTP_COOKIE_VARS;
33 setcookie($this->name, $this->ticket, 0, "/");
34 }
35 }
36
37 ?>

MailToCvsAdmin">MailToCvsAdmin
ViewVC Help
Powered by ViewVC 1.1.26 RSS 2.0 feed