On 7/15/00, Dave Watts penned:
>In any case, CF doesn't control how the browser uses cookies. You could
>write CF code all day long to set a cookie for another domain, but that
>doesn't mean that the browser will obey that code if the browser has been
>designed to follow the cookie specification. When I tried just setting a
>cookie for another domain, CFCOOKIE threw an error:
>
>"Error Occurred While Processing Request
>Error Diagnostic Information
>Error attempting to set a cookie value with CFCOOKIE.
>Invalid CFCOOKIE DOMAIN attribute"

The only time I get that error is if I don't include a leading dot. 
When I was trying to set it for a different domain, WITH the leading 
dot, I didn't get an error, but the cookie isn't set.

The problem with the leading dot is, it's impossible to set a cookie 
that will work with and without a subdomain. It can only be set so 
all subdomains will work. In other words, if I'm on a page:

http://domain.com

Then I can use cfcookie without setting the domain and it will be 
good for http://domain.com, but won't work with www.domain.com, etc., 
or I can set a cookie WITH a domain attribute as cfcookie 
domain=".domain.com", with the leading dot, which will be good for 
www.domain.com or secure.domain.com etc., but won't work on plain old 
domain.com because http://domain.com doesn't have a dot in front of 
it.
-- 

Bud Schneehagen - Tropical Web Creations

_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/
ColdFusion Solutions / eCommerce Development
[EMAIL PROTECTED]
http://www.twcreations.com/
954.721.3452
------------------------------------------------------------------------------
Archives: http://www.mail-archive.com/[email protected]/
To Unsubscribe visit 
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or send a 
message to [EMAIL PROTECTED] with 'unsubscribe' in the body.

Reply via email to