cLFlaVA ---
Your code worked when kept the return false and return true statements below it, but it still submited my page after the pop-up validation box came up and I clicked ok.
I didn't know I was supposed to use your code exactly, so I tried it both with the return false and true...
I'm not sure I understand your question and comment but I'll try and answer. I am by no means a programmer (I am a web designer) and have been trying to do the best I can to make this site work that was left for me to finish up when I was hired. From the begining it has been a mess, so I just...
I made then changes as you suggested to my script, but when I run through that page is give me an error when I try to submit...
Error: 'curr_annual_salary' is underdefined
I am using a SQL statement to determine what fields are displayed or hidden.
<%
IF WageType.Fields.Item("wage_type").Value = "Exempt Salaried" Then
%>
Display these fields....
<%
Else
%>
Display these fields....
I have a form that is broken out into 4 pages. Dependant on whether you select "Exempt" or "Non-Exempt" on page 3 you will have different choices on page 4.
How can I modify my script so that it only validates the fields that are being displayed.
In this case let's say that only the "Current...
I finally figured it out myself... i know... i know... pretty hard to believe. thank you Cory for your help. i really appreciate your patience with me. you are very kind.
That really helped out. It now checks my name, last name, title and contract field.
My Effective Date validation is still not working. I've tried many variation of the code and the onsubmit call to it, but no luck.
I'm thinking it has something to do with where it says "input", should I...
Hopefully I made some changes that are more towards what you are telling me.
<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<HTML>
<HEAD>
<META NAME="GENERATOR"...
Sorry I don't know javascript well... I only copy and paste it and try to modify it so it works for me. I don't know that the protocol is for naming functions and then calling them in your form. I thought there were probably reserved words that you have to use that I don't know.
I appologize...
What should I call the other validate_form function? When I removed the Onclick call in my submit buttons the page would still go to the next page, even when the alert box popped up.
Not really sure that this is going to make a difference.... but here you go.
<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<HTML>
<HEAD>
<META NAME="GENERATOR"...
<!--FORM FIELD VALIDATION-->
<script type="text/javascript">
function validate_required(field,alerttxt)
{
with (field)
{
if (value==null||value=="")
{alert(alerttxt);return false}
else {return true}
}
}
function validate_form(thisform)
{
with (thisform)
{
if...
I can not provide a link it is for our intranet website. All I can do is give you the code. Was the javascript and form handler not enough? Let me know what else you need.
Thank you.
That onsubmit came from the person that responded to my last post before today.
I changed it to what you proposed and it did not make a difference. The form still submits without checking my first set of field boxes for name, title etc.
Thanks.
It's me again... back to bother you. I just realized that after I modified this code it no longer validates the first part where I am validating "Name, Last Name, Title, Contract"
<!--FORM FIELD VALIDATION-->
<script type="text/javascript">
function validate_required(field,alerttxt)
{
with...
Does big companies like say Cingular have these same issues, or do they have a prevention method.
I am not familiar with security images, is that like what you see when you buy tickets from ticketmaster.com or when I login to my bank account and it asks you to type the letters/numbers that you...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.