Thanks for the info, Rob.
 
The purpose here is to determine how my server-side form
validation results will be sent back to the form page.
 
If JS is enabled, then I can use Ajax to send them back,
if not, then the page will have to be refreshed.
 
This is very important for forms that are embedded in the
middle of a page where refreshing the page would cause
the user to have to scroll back down to the form to see the
results if a refresh is used.
 
Rick
 
 
From: jquery-en@googlegroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Rob Desbois
Sent: Friday, April 20, 2007 9:14 AM
To: jquery-en@googlegroups.com
Subject: [jQuery] Re: Best way to determine if a user has Javascript
enabled?
 
>From where?
If javascript runs, they have it enabled - if it doesn't, they don't!

Are you wanting to pass this information to your server? Something like the
following should work for that:

<a id='js_detect' href='/foo.php'>Load</a> 
<script type='text/javascript'><!--
   $(document).ready(function() {
      var href = $("#js_detect").attr("href");
      href += "?javascript=true";
      $("#js_detect").attr("href", href); 
   });
// -->
</script>

If the user doesn't have javascript or it's not enabled, the href won't be
changed.

HTH,
rob
On 4/20/07, Rick Faircloth <[EMAIL PROTECTED]> wrote:

Good morning, all...

Is there a fool-proof way to determine if a user has Javascript
enabled in their browser?

Rick





-- 
Rob Desbois
Eml: [EMAIL PROTECTED]
Tel: 01452 760631
Mob: 07946 705987
"There's a whale there's a whale there's a whale fish" he cried, and the
whale was in full view.
...Then ooh welcome. Ahhh. Ooh mug welcome. 

Reply via email to