Can we use a common cookie in PHP for different domains. e.g. domainA.com and domainB.com (Not for subdomain) .If yes then how. Please explain me with an example. Thanks
Cookies available only for that domains and sub domains. For more details refer
You can find more information here also
Cookies are available for your domain and it's shbdomains only. However, a good solution would be to have a script working in a server that reads information from a neutral domain, and fetches the right information. For example: d1.com and d2.com both want to fetch the login details of a given member. They both turn to example, d1.com with the login data, which returns to them the member details, and they set their cookies accordingly, each on its own domain.