Jump to content

[SOLVED] URGENT: ARE COOKIES GLOBAL TO A WEBSITE? :)


newbie69

Recommended Posts

Hi guys,

 

I seem to having some issues with reading a cookie from different parts of my website.

 

I have been suspecting my code for a long time only to come to realise that my cookie cant be read across the site.

 

I have created a simple test to show that if I set a cookie on one page in folder of the website, it cannot be accessed if i call it from another folder.

 

A page that sets a cookie in the folder "Premier":

 

http://www.quickbooks.co.za/products/accounting/premier/setCookie.php

 

A page that reads the cookie, which reside in the folder "Premier":

 

http://www.quickbooks.co.za/products/accounting/premier/printCookie.php

 

this above works, so cool :) BUT

 

why cant the cookie that was set above work when read when i call it from a page in a folder outside of folder "premier":

 

In a folder out side of "premier" :

http://www.quickbooks.co.za/products/accounting/accountant/printCookie.php

 

 

Is there way for me to make cookies GLOBAL? i.e have it created anywhere on the site, and access it anywhere?

 

Thanks alot in advanced!

 

Sudhir

 

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.