Anyone tell me how to properly set the path for Javascript 
cookies using Bill Dortch's generic code?

I want to set the cookies such that they will be retrieved 
from any sub-directory below a certain main directory, i.e.:

http://www.abc.com/main/index.html 

   http://www.abc.com/main/sub1/page.html

   http://www.abc.com/main/sub2/page45.html

etc... so if a user sets a cookie from any of the above 
directories, it will be retrieved from within any of the 
others.

Dortch's code lets you specify path and domain, with the 
default (between the "") being null:

((path == null) ? "" : ("; path=" + path)) + 
((domain == null) ? "" : ("; domain=" + domain)) + 

...but no matter what combinations of path/domain I try, the 
cookies are only being retrieved within the same directories 
they're set from, i.e., if set from /main/sub2/page45.html, 
they'll be retrieved from all the other pages in /main/sub2/, 
but not from /main/, /main/sub1/, and so on.

Help.  I seem to be missing something here.


-----------
Brent Eades, Almonte, Ontario
   E-mail: [EMAIL PROTECTED]
           [EMAIL PROTECTED]
   Town of Almonte site: http://www.almonte.com/
   Business site: http://www.federalweb.com

____________________________________________________________________
--------------------------------------------------------------------
 Join The Web Consultants Association :  Register on our web site Now
Web Consultants Web Site : http://just4u.com/webconsultants
If you lose the instructions All subscription/unsubscribing can be done
directly from our website for all our lists.
---------------------------------------------------------------------

Reply via email to