Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

Re: Re: CGI and JavaScript

by stuffy (Monk)
on Jun 03, 2001 at 03:51 UTC ( [id://85243]=note: print w/replies, xml ) Need Help??


in reply to Re: CGI and JavaScript
in thread CGI and JavaScript

You are suggesting using it for form validation. That makes since, but do you worry about people that don't have it turned on? How do you handle that? If someone doesn't have javascript on, are they just out of luck? In that case have you lost out on someones buisness (or has whom ever hired you lost out on someones buisness?) I understand on high traffic sites it is probably a good thing, but what about a backup plan for the people that don't have it on?

by the way, there are cars designed for people that like to drive with bald tires, you can usually find them at the local drag strip :~)
update: corrected spelling

Stuffy
That's my story, and I'm sticking to it, unless I'm wrong in which case I will probably change it ;~)

Replies are listed 'Best First'.
Re: Re: Re: CGI and JavaScript
by thabenksta (Pilgrim) on Jun 04, 2001 at 09:27 UTC

    This can be solved by checking if the user has javascript enabled, if not, pass a hidden flag then have the cgi script do it. You could so something like this.

    HTML Form <form> <noscript> <input type="hidden" name="jsenabled" value="yes"> </noscript> </form> CGI Script if ($q->param('jsenabled') eq "Yes") { #perform validation }
    -thabenksta
    my $name = 'Ben Kittrell'; $name=~s/^(.+)\s(.).+$/\L$1$2/g; my $nick = 'tha' . $name . 'sta';

      You're trusting that input is from your form, and that your form has gone unedited. Clientside .*script is helpful, but is no substitute for good practice.

      After Compline,
      Zaxo

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://85243]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others sharing their wisdom with the Monastery: (9)
As of 2024-03-28 12:24 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found