0

Hi I want JavaScript code to remove cookies from browsers when my website opens..

Issue: I am going to signup to the my wesite, If signup was not sucessful means and next time i open to the my website it will automatically goes to the signup page and if i delete all cookies on my browser then it will goes to my website home page..

can any one help in this issue...

thanq....

Udaykumar
  • 1
  • 1

1 Answers1

0

How can I delete all cookies with JavaScript?

var cookies = document.cookie.split(";");
for (var i = 0; i < cookies.length; i++)
eraseCookie(cookies[i].split("=")[0]);
Community
  • 1
  • 1
fxck
  • 4,898
  • 8
  • 56
  • 94