BrMe
BrMe

Reputation: 315

Loosing cookie when swich from http to https

I have the option in my site to change language.

When user change language ,its saved in cookie, so the other pages know which language to display!

Some of the pages are in https. And in these pages I don't get the selected language.

Is there any way to use the same cookie for http and https?

Upvotes: 1

Views: 1612

Answers (2)

Guffa
Guffa

Reputation: 700870

No, there isn't. The cookies are local to the domain, and the http and https pages are considered to be in different domains.

The https pages are encrypted, so sending the same cookies for a http request would leak that information, and compromise the encryption.

Upvotes: 3

Related Questions