|
-
Nov 18th, 2006, 06:13 AM
#1
Thread Starter
Member
validation in javascript
i am new in programming
i am having 10 asp forms i want to do validation i create separate file commonfunctions.js where i will keep all common functions in my project
now pl tell me how to write validation code
which will check all textboxes should not be blank how to refer all
forms in function
pl pl. help me
-
Nov 19th, 2006, 10:38 AM
#2
Re: validation in javascript
First, do the validation server-side. When you're satisfied with that, then you can do some validation client-side.
For that, learn JavaScript. Really learn it, not look at two small scripts and then come to a forum asking people to do it for you.
All the buzzt
 CornedBee
"Writing specifications is like writing a novel. Writing code is like writing poetry."
- Anonymous, published by Raymond Chen
Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.
-
Nov 22nd, 2006, 05:58 PM
#3
Stuck in the 80s
Re: validation in javascript
Validation in JavaScript should only complement validation on the server-side. Otherwise, if the user has JavaScript turned off, you're screwed.
Unless of course, you're submitting the form via JavaScript and only via JavaScript -- then the user can't do anything.
-
Nov 22nd, 2006, 07:59 PM
#4
Re: validation in javascript
Sure. He can manually submit garbage to your server and corrupt your database.
All the buzzt
 CornedBee
"Writing specifications is like writing a novel. Writing code is like writing poetry."
- Anonymous, published by Raymond Chen
Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.
-
Nov 23rd, 2006, 03:36 AM
#5
Re: validation in javascript
There is no reliable way of ensuring where a HTTP request comes from - you must deal with whatever you get.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|