我有這些參數的餅乾:如何使用PHP或刪除的cookie僅Http JS
Name: workgroup_session_id
Content: ""
Domain: agrobman1.tsi.lan
Path: /
Send for: Any kind of connection
Accessible to script: No (HttpOnly)
Created: Wednesday, November 4, 2015 at 9:31:58 AM
Expires: When the browsing session ends
我曾嘗試使用PHP使用此代碼刪除cookie:
setcookie("workgroup_session_id", "\"\"", time() - 3600, "/", "agrobman1.tsi.lan", false, true);
但我我仍然無法刪除它。有誰知道如何使用PHP或JS刪除這種類型的cookie?
謝謝,PHP方式做到了。 – anton2g
您無法從javascript中刪除HttpOnly cookie。 –