I am working on a web based application with JSP and servlets. I am using the Cookie class and response.getCookie method to set cookies in the browser. But I have a doubt as to how will the behavior be when the browser does-not allow cookies, through browser setting. In this case, will the servlet code like getCookie throw any exception? How will be the behavior ?
Share
No. It will merely return
null.Exactly the same as if the user had never visited your site before and directly opened that page.