March 2002
Intermediate to advanced
528 pages
21h 29m
English
setcookie
void setcookie(stringname[, stringvalue[, intexpiration[, stringpath[, stringdomain[, boolis_secure]]]]])
Generates a cookie and passes it along with the rest of the header
information. Because cookies are set in the HTTP header,
setcookie( ) must be called before any output is
generated.
If only name is specified, the cookie with
that name is deleted from the client. The
value argument specifies a value for the
cookie to take, expiration is a Unix
timestamp value defining a time the cookie should expire, and the
path and domain
parameters define a domain for the cookie to be associated with. If
is_secure is true, the
cookie will be transmitted only over a secure HTTP connection.
Read now
Unlock full access