코드:
결과보기 »
<!DOCTYPE html> <?php $cookieName = "city"; $cookieValue = "서울"; // 쿠키를 삭제함. unset($_COOKIE["cookie"])와 같음. setcookie($cookieName, $cookieValue, time()-60, "/"); ?> <html lang="ko"> <head> <meta charset="UTF-8"> <title>PHP Cookie And Session</title> </head> <body> <?php echo "{$cookieName}라는 이름의 쿠키가 삭제되었습니다."; ?> </body> </html>