473,795 Members | 2,974 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Form Validation Help - Possible??

Hi,

I would like to know if this scenario is possible using Javascript.

Form has input field such as Age, weight etc. If a user does not
put in data in the field, I would like to open another window and
ask user why they left it blank. I then want to save that "why data"
in an access database table. I don't want to force them to put in
age, but I need to know why they skipped the field.

Also, I would like to do this through a PDF form vs. HTML.

Any help and/or references is much appreciated. Code sample even better!

Thanks,
Dave
Jul 20 '05 #1
3 1243
On Wed, 21 Jan 2004 14:59:55 GMT, Dave <dh********@NOS PAMbioreg.com> wrote:
Form has input field such as Age, weight etc. If a user does not
put in data in the field, I would like to open another window and
ask user why they left it blank. I then want to save that "why data"
in an access database table. I don't want to force them to put in
age, but I need to know why they skipped the field.


It is possible, but there is no reason to do it. If you are going to save
the data to a database, which must be done from the server, then you may
as well direct the user to a page where they can enter your "why data"
before progressing further.

Alternatively, just place next to the age input, a text box or a menu that
they can use to give their reasons.

Both of these suggestions avoid the issue of a browser with JavaScript
disabled. However, your approach introduces another problem: a pop-up
window. My browser will block it, so there's no way for you to get the
information from me, and I won't be the only one.

Mike

--
Michael Winter
M.******@blueyo nder.co.invalid (replace ".invalid" with ".uk" to reply)
Jul 20 '05 #2
Thanks for the reply. Okay, I agree with your popup assessment. I don't
really want to clutter the main form, so another page seems good. Can I
maintain control from the main page so that it takes them back to the
same point where they were previously?

Do you know any site with code that might be able to help with this task?

Especially, the database connection and control of the child page.

Also, how about this running in a PDF file?

Thanks,
Dave
Michael Winter <M.******@bluey onder.co.invali d> wrote in
news:op******** ******@news-text.blueyonder .co.uk:
On Wed, 21 Jan 2004 14:59:55 GMT, Dave <dh********@NOS PAMbioreg.com>
wrote:
Form has input field such as Age, weight etc. If a user does not
put in data in the field, I would like to open another window and
ask user why they left it blank. I then want to save that "why data"
in an access database table. I don't want to force them to put in
age, but I need to know why they skipped the field.


It is possible, but there is no reason to do it. If you are going to
save the data to a database, which must be done from the server, then
you may as well direct the user to a page where they can enter your
"why data" before progressing further.

Alternatively, just place next to the age input, a text box or a menu
that they can use to give their reasons.

Both of these suggestions avoid the issue of a browser with JavaScript
disabled. However, your approach introduces another problem: a pop-up
window. My browser will block it, so there's no way for you to get the
information from me, and I won't be the only one.

Mike


Jul 20 '05 #3
On Wed, 21 Jan 2004 15:41:54 GMT, Dave <dh********@NOS PAMbioreg.com> wrote:
Thanks for the reply. Okay, I agree with your popup assessment. I don't
really want to clutter the main form, so another page seems good. Can I
maintain control from the main page so that it takes them back to the
same point where they were previously?
Yes, it too can be done. It will most likely implemented using a session
cookie, but it could depend on what you have on your page.
Do you know any site with code that might be able to help with this task?
The best place to ask would depend on what language you will use
server-side.

ASP:
General questions: microsoft.publi c.inetserver.as p.general
Database-related: microsoft.publi c.inetserver.as p.db

CGI:
comp.lang.perl
comp.infosystem s.www.authoring.cgi

JSP:
http://java.sun.com/products/jsp/

PHP:
comp.lang.php

Also, how about this running in a PDF file?


I don't know anything about PDF scripting. Sorry.

Mike

--
Michael Winter
M.******@blueyo nder.co.invalid (replace ".invalid" with ".uk" to reply)
Jul 20 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

21
3925
by: Stefan Richter | last post by:
Hi, after coding for days on stupid form validations - Like: strings (min / max length), numbers(min / max value), money(min / max value), postcodes(min / max value), telefon numbers, email adresses and so on. I thought it might be a better way to programm an automated, dynamic form validation that works for all kinds of fields, shows the necessary error messages and highlights the coresponding form fields.
11
8759
by: Jim | last post by:
Hi, I keep getting form results emailed to me that would indicate a form from my web site is getting submitted with all fields blank or empty, but my code should preventing users from proceeding if they left any field blank. My guess is that someone is trying to hack the site using the form to gain entry or run commands -- I don't really know since I'm not a hacker. I just know that forms are often susceptible to these kinds of...
5
2145
by: Danny | last post by:
Does anybody have a nice method of forcing a user to enter a value into a form using asp? I think the best is to have a popup when they hit submit that will stay on the same page and then just alert the user to enter something in so and so text box. Thanks in advance
6
4345
by: Charles Banas | last post by:
weird subject - i hope more than just one curious regular will hear me out. :) ok, i've got a bit of a big problem, and i need answers as soon as possible. i know this forum is meant for web developers, but is relevant discussion. i'm not OT here unless someone thinks i'm trolling (which i'm not, obviously). then i'll disappear and never show my face again. :P
16
2253
by: Hosh | last post by:
I have a form on a webpage and want to use JavaScript validation for the form fields. I have searched the web for form validation scripts and have come up with scripts that only validate individual fields, such as an "Email Validation Script" or a "Phone Validation Script". Is it ok to put all these scripts on page as they are or should they be joined in some way together to be one script? I'm a total JavaScript newbie and am completely...
9
4181
by: julie.siebel | last post by:
Hello all! As embarrassing as it is to admit this, I've been designing db driven websites using javascript and vbscript for about 6-7 years now, and I am *horrible* at form validation. To be honest I usually hire someone to do it for me, grab predone scripts and kind of hack out the parts that I need, or just do very minimal validation (e.g. this is numeric, this is alpha-numeric, etc.)
7
6999
by: h7qvnk7q001 | last post by:
I'm trying to implement a simple server-side form validation (No Javascript). If the user submits a form with errors, I want to redisplay the same form with the errors highlighted. Once the form is correct I need to submit to another page that uses the form data. I first tried making the form submit action= field point to the same file. When the form was correct, I tried loading the next page by using <META http-equiv refresh>. But...
27
4759
by: Chris | last post by:
Hi, I have a form for uploading documents and inserting the data into a mysql db. I would like to validate the form. I have tried a couple of Javascript form validation functions, but it appears that the data goes straight to the processing page, rather than the javascript seeing if data is missing and popping up an alert. I thought it may be because much of the form is populated with data from the db (lists, etc.), but when I leave...
11
3002
by: Rik | last post by:
Hello guys, now that I'm that I'm working on my first major 'open' forms (with uncontrolled users I mean, not a secure backend-interface), I'd like to add a lot of possibilities to check wether certain fields match certain criteria, and inform the user in different ways when the data is wrong (offcourse, this will be checked on posting the data again, but that's something I've got a lot of experience with). Now, offcourse it's...
10
5726
by: gweasel | last post by:
What is the best way to apply a Validation Rule - or rather, where is the best place to put it? Is there an advantage to putting it on the field in the table vs setting the validation rule on the form the control is on? Basically I have a number of controls in a form that are required, and to check it I am setting the Validation Rule to "<>"IsNull" so that when the user tries to tab through/click out of a required area without entering...
0
9672
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9519
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10215
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10165
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10001
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
7541
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6783
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
1
4113
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
3
2920
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.