RE: JSP question

2003-10-21 Thread Matt Raible
A better solution for what you're doing is to leave the button as type=submit and remove its onclick event. Instead, add an onsubmit handler to form that calls return validateForm() - return false in your function when validation fails. HTH, Matt -Original Message- From: epyonne

RE: JSP question

2003-10-21 Thread Peter Guyatt
Hi There, Why dont you change the button back to a submit and then add a onSubmit='return validation();' to you form ? Thats what we do Eg. Script function valid () { if (document.form.val.value.length 1) { alert(Please enter a value);

RE: JSP question

2003-10-21 Thread Walker Chris
Most likely document.form1 is not visible in the browser object model. There are various ways to address the form, but the most portable in this case is probably document.forms[0]. Chris -Original Message- From: epyonne [mailto:[EMAIL PROTECTED] Sent: 21 October 2003 16:35 To: Tomcat

Re: JSP question

2003-10-21 Thread epyonne
] To: 'Tomcat Users List' [EMAIL PROTECTED] Sent: Tuesday, October 21, 2003 10:45 AM Subject: RE: JSP question Most likely document.form1 is not visible in the browser object model. There are various ways to address the form, but the most portable in this case is probably document.forms[0

Re: JSP question

2003-10-21 Thread epyonne
Thank you Matt and Peter for the suggestion. It works!!! - Original Message - From: Peter Guyatt [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Sent: Tuesday, October 21, 2003 10:42 AM Subject: RE: JSP question Hi There, Why dont you change the button back to a submit

Re: JSP question [solved]

2003-10-21 Thread laurent marot
works fine written this way : html head titleblah blah blah/title link rel=stylesheet href=css/standard.css type=text/css /head body script LANGUAGE=JavaScript function validateForm(){ if(document.form1.ani.value == ){ alert(Please enter an ANI); return; } document.form1.submit(); }

RE: JSP Question

2003-01-08 Thread Tim Moore
-Original Message- From: Luc Foisy [mailto:[EMAIL PROTECTED]] Sent: Wednesday, January 08, 2003 1:54 PM To: Tomcat User List (E-mail) Subject: JSP Question I am trying to use %@ include file=filename % I am sending to the page that has this with the line:

RE: JSP Question

2003-01-08 Thread Ricardo_Bosch
I may be referring to an oldschool version of tomcat but the include directive occurs during compilation, not execution. So to do what you want you'd have to say % if(goo){% %@ include file=filenameA % % }else{ % %@ include file=filenameB % % } % or do your thing

RE: JSP Question

2003-01-08 Thread Luc Foisy
pages based on applicationJar.getPageName() instead of including dynamic content in a common page -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Sent: Wednesday, January 08, 2003 3:16 PM To: [EMAIL PROTECTED] Subject: RE: JSP Question I may be referring

Re: JSP question

2002-03-28 Thread Jeff Larsen
Assuming you have a controller servlet that could load the hint text from the database, why not have a static hashtable in your servlet code that is initialized with the values from the database in the init() method. Then as each session is initialized, you could put a reference to the hashtable

RE: jsp question about uploading images to a database

2002-02-01 Thread Marc Ostrow
http://www.servlets.com/cos/index.html These classes will get you the upload part. -Original Message- From: Magnus Jansson [mailto:[EMAIL PROTECTED]] Sent: Friday, February 01, 2002 9:20 AM To: [EMAIL PROTECTED] Subject: OT: jsp question about uploading images to a database I want to

Re: Jsp question

2001-06-28 Thread Matt Christensen
Two quick ideas: 1. Include in each of your forms a html hidden tag that has a name value that will be common for each form, and a value dependent on the identity of the form. Then you can get from the request object the expected key value and find the form. input type=hidden