Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Web Programming > JavaScript > Javascript
|
Javascript General Javascript discussions.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Javascript section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old July 21st, 2005, 07:57 AM
Friend of Wrox
 
Join Date: Jun 2004
Posts: 128
Thanks: 0
Thanked 0 Times in 0 Posts
Default How to detect whether cookie is enabled or not.

Hi,
I have to detect in the ASP form with the help of javascript whether cookie is enable or disabled. I have tried with navigator.cookieenabled=true but this is not working. Is there any different solution for this.


Thanks and Regards
Lily Bauri

 
Old July 21st, 2005, 09:04 AM
joefawcett's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 3,074
Thanks: 1
Thanked 38 Times in 37 Posts
Default

Firstly do you want to do client-side detection or server-side. You state an ASP form but the navigator object is client-side. And "cookieenabled" should be "cookieEnabled". Whichever way you try it's possible to use trial and error. Try to read a cookie. If nothing returns then try to set one and read the return value.

--

Joe (Microsoft MVP - XML)
 
Old July 26th, 2005, 03:53 AM
Friend of Wrox
 
Join Date: Jun 2004
Posts: 128
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I have tried with this, but this is showing the same alert as "Cookie Enabled" what I have written as the error message for cookieEnabled=false.
Give some other option to find out.






Similar Threads
Thread Thread Starter Forum Replies Last Post
Ajax enabled website priyan.viji .NET Framework 2.0 0 August 20th, 2007 04:33 AM
paging enabled but hidden buttons DarkForce ASP.NET 2.0 Basics 1 July 27th, 2007 02:52 AM
Authentication is not enabled ayyub123 ASP.NET 2.0 Basics 0 May 29th, 2007 01:49 AM
Trigger Enabled or Disabled? smshinde Oracle 2 March 1st, 2007 06:02 AM
Validate only if enabled bleutiger Other Programming Languages 0 April 25th, 2006 07:15 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.