You are writing a PHP script and you need to set a cookie. How would you do this?

  • setcookie()
  • create_cookie()
  • set_cookie()
  • bake_cookie()
To set a cookie in PHP, you can use the setcookie() function. This function allows you to define the cookie name, value, expiration time, path, domain, and other parameters. By calling setcookie(), you can set the desired cookie in your PHP script. Refer to: http://php.net/manual/en/function.setcookie.php
Add your answer
Loading...

Leave a comment

Your email address will not be published. Required fields are marked *