Cookie PHP ayarı değil

0 Cevap php

Bu süper kolay olduğunu düşündüm, ama ben boşuna anlamaya çalışıyorum son yarım saat geçirdim.

$unique_id = uniqid(microtime(),1);

if (is_null($_COOKIE['client_id']))
  {
  setcookie("client_id", $unique_id);
  }

Ne oluyor But when I go to check the cookie through $_COOKIE['client_id'], I get a null value. Herhangi bir fikir?

0 Cevap