Added function to window object

Function viewCookies added to window object.