S
S
Sergey2014-10-20 16:58:20
PHP
Sergey, 2014-10-20 16:58:20

How can I set cookies to the client in php?

I was asked this question at an interview, asked to list all the possible ways.
Well, besides setcookie() and http headers directly, what else can you do? Is it possible?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
#
# artur #, 2014-10-20
@passshift

nothing, well, except for js and jquery

A
Alexey Skobkin, 2014-10-21
@skobkin

With default PHP settings, session_start() also sets a cookie. It depends on how the question is asked. If this is a nitpicking question in the style of "what functions cause the cookie to be set" - then yes.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question