PHP and cURL cookies

前端 未结 3 1323
小蘑菇
小蘑菇 2020-12-20 07:37

I am trying to setup a php page which uses cURL to hit a third party server to log them in. Right now my code does successfully log in to the third party server, but since c

3条回答
  •  情深已故
    2020-12-20 07:45

    The user's browser will most probably not allow you to set cookies for another domain anyway.

    You can, in your PHP code, login and fetch a session cookie for (e.g.) Hotmail. But you won't be able to pass that session on to the user (so he/she would also be logged in).

    This is because many browsers and configurations deny setting 3rd party cookies.

提交回复
热议问题