Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

Coding Forum


You are currently viewing our Coding Forum as a guest. Please register to participate.
Login



Reply
Your recommended Form Field Validation Javascript
Old 12-18-2003, 05:03 AM Your recommended Form Field Validation Javascript
Average Talker

Posts: 28
Trades: 0
What is your favorite Javascripts for Form Field validation (email, drop down men, text fields,)

Thank you
bestempire is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 12-18-2003, 06:29 AM
Ultra Talker

Posts: 377
Trades: 0
Is it so neccesary to use JS? I prefer php anyway...
__________________
andrews_john

Please login or register to view this content. Registration is FREE
andrews_john is offline
Reply With Quote
View Public Profile Visit andrews_john's homepage!
 
Old 12-18-2003, 04:38 PM
praveen's Avatar
Life is a Dream

Posts: 3,591
Name: Praveen
Location: Chennai, India
Trades: 0
here is anice one which i use..

http://www.javascript-coder.com/html...lidation.phtml

just follow the instructions..
__________________

Please login or register to view this content. Registration is FREE
-
Please login or register to view this content. Registration is FREE
-
Please login or register to view this content. Registration is FREE
-
Please login or register to view this content. Registration is FREE
praveen is offline
Reply With Quote
View Public Profile
 
Old 12-20-2003, 08:01 AM
Average Talker

Posts: 28
Trades: 0
Very good one, but it doesnot support Radio Buttion validation
__________________

Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE
bestempire is offline
Reply With Quote
View Public Profile
 
Old 12-21-2003, 12:50 PM
ACJavascript's Avatar
Humble Mod

Posts: 548
Location: CT, USA
Trades: 0
Why dont you post your form and tell us what you wan the form to validate, I will make it for you.
__________________

Please login or register to view this content. Registration is FREE
- 100 Satisfied Customers - Custom Programming and Web Development
ACJavascript is offline
Reply With Quote
View Public Profile Visit ACJavascript's homepage!
 
Old 12-22-2003, 01:40 PM
Average Talker

Posts: 28
Trades: 0
Here is the link
http://www.asiantrailsvietnam.com/hotel/bookhotel.php

I would like to validate at the same time the text boxes, email, drop down menus (as in date fields) and Radio buttons

thanks for your help

bestempire
bestempire is offline
Reply With Quote
View Public Profile
 
Old 12-22-2003, 05:02 PM
ACJavascript's Avatar
Humble Mod

Posts: 548
Location: CT, USA
Trades: 0
hey best,

I noticed that your formwent to a php script.
WOuld you prefer me to do it in PHP,,, or do it in javascript?
__________________

Please login or register to view this content. Registration is FREE
- 100 Satisfied Customers - Custom Programming and Web Development
ACJavascript is offline
Reply With Quote
View Public Profile Visit ACJavascript's homepage!
 
Old 12-22-2003, 10:59 PM
Average Talker

Posts: 28
Trades: 0
I would prefer the JS since i would like it to check the field before going to the php script (i think it is faster)
__________________

Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE
bestempire is offline
Reply With Quote
View Public Profile
 
Old 12-23-2003, 03:03 AM
ACJavascript's Avatar
Humble Mod

Posts: 548
Location: CT, USA
Trades: 0
Hey best,

Okay, I have attached a zip file to this post.

The zip file includes FormTest.html, this html file has the javascript validation script and your form on it.

Let me know if somthing is wrong.

I put all of the error messages on top so you can edit them

Hope it works for you
Attached Files
File Type: zip formvalidate.zip (3.3 KB, 10 views)
__________________

Please login or register to view this content. Registration is FREE
- 100 Satisfied Customers - Custom Programming and Web Development
ACJavascript is offline
Reply With Quote
View Public Profile Visit ACJavascript's homepage!
 
Old 12-23-2003, 04:20 AM
Average Talker

Posts: 28
Trades: 0
Hey ACJavascript,

Your script is very cool and neat and easy to edit. Truly thanks.

In case i need to validate the radio fields (in my form it is the payment method), how do you suggest?

Thanks again
__________________

Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE
bestempire is offline
Reply With Quote
View Public Profile
 
Old 12-23-2003, 12:08 PM
ACJavascript's Avatar
Humble Mod

Posts: 548
Location: CT, USA
Trades: 0
Hey best,

I put in a validate for the radio buttons, But how would you like to check them??

Do you want one checked no matter what? or both checked?
__________________

Please login or register to view this content. Registration is FREE
- 100 Satisfied Customers - Custom Programming and Web Development
ACJavascript is offline
Reply With Quote
View Public Profile Visit ACJavascript's homepage!
 
Old 12-23-2003, 03:47 PM
Average Talker

Posts: 28
Trades: 0
Hey ACJavascript,
Yeah, i have seen that you put the field for the radio button,

I would like the user to check one of those radio buttons to choose the payment method

Thanks for your help

bestempire
__________________

Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE
bestempire is offline
Reply With Quote
View Public Profile
 
Old 12-23-2003, 03:54 PM
ACJavascript's Avatar
Humble Mod

Posts: 548
Location: CT, USA
Trades: 0
if(document.theForm.Payment_by.value==""){
alert(Payment)
document.theForm.Payment_by.focus()
return;
}

That code above pretty much says if none are checked error.
__________________

Please login or register to view this content. Registration is FREE
- 100 Satisfied Customers - Custom Programming and Web Development
ACJavascript is offline
Reply With Quote
View Public Profile Visit ACJavascript's homepage!
 
Reply     « Reply to Your recommended Form Field Validation Javascript
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.36627 seconds with 13 queries