Home > Contents > Index >
satellite.cookie
Sets a cookie on the user's browser.
Syntax
<satellite.cookie name="cookie_name
" value="cookie_value
" timeout="timeout
" secure="true|false" xhtml="true|false" url="URL
" [domain="domain
"]/>Parameters
name (required)
- Name of cookie to set.
value (required)
- Value of the cookie being set.
timeout (required)
- Required. Timeout value of cookie, in seconds. To set a session-long cookie, set this value to -1.
secure (required)
- Set to
true
to indicate a secure cookie; set tofalse
to indicate an non-secure cookie.
xhtml
- Set to
true
to indicate if the generated mark up is strict xhtml compliant.
url (required)
- A valid URL. This value restricts the sending of the cookie from the client to this URL only. The path must include the context that set the cookie, for example,
/cs
, which makes the cookie visible to all directories on the server under/cs
.
domain (optional)
- Optional. Specify a valid domain name. This value restricts the sending of the cookie from the client to addresses in this domain only
Description
The
satellite.cookie
tag sets a cookie on the user's browser.HTML requires that serverside cookies must be set in the
head
section of a Web page. However, you don't have to put thesatellite.cookie
tag inside thehead
section of a Sites element; you can place it anywhere within the element, because Sites-Satellite causes the cookie to be set in a second request to the page. Thesatellite.cookie
tag invokes the CookieServer to set the cookie.Example
This example sets the cookie
mycookie
on the client with the valuefrank
. The cookie expires 600 seconds from the time it is created.<satellite.cookie NAME="mycookiename" VALUE="mycookievalue" TIMEOUT="600" SECURE="false" XHTML="false" URL="/cs/ContentServer" />
Home > Contents > Index > Oracle XML Tag Reference
Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved.