Date: 10/16/00
- Next message: Ulf Wendel: "Re: [phplib] hidding template blocks"
- Previous message: Marko Kaening: "Re: [phplib] Problem with examples for template class"
- Next in thread: Jens Benecke: "[phplib] Re: PHPLIB suggestion for FORM elements & validation"
- Reply: Jens Benecke: "[phplib] Re: PHPLIB suggestion for FORM elements & validation"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Hi,
for now, if I use the Javascript validation function in the PHPLIB
oohforms class, the code looks like this:
if (window.RegExp) {
var reg = new RegExp("^.+$","g");
if (!reg.test(f.elements[0].value)) {
alert("You did not enter any text!");
f.elements[0].focus();
return(false);
}
}
Would it be possible to change this to read "f.$form_element_name.value",
e.g. f.address.value for an input field that is called "address"? I am
asking this because I found out that some browsers mix up the order of form
elements when they are in HTML table structures. E.g. if I have a 2x2 table
with four input fields like
Name1: [_____________] Name2: [_____________]
Name3: [_____________] Name4: [_____________]
on Linux Netscape 4.75 the browser would first check and focus Name1, then
check Name3 but jump to Name2, and not mention Name4 at all. All form
elements are defined identically.
I looked into the oohforms.inc but could not really find a starting point.
I'd be happy if someone pointed me in the right direction. :)
Thanks!
-- *ACHTUNG*: die .pinguin.conetix.de Addresse läuft aus, bitte Addressbuch aktualisieren! · http://www.hitch-hiker.de/ - Die KOSTENLOSE Mitfahrzentrale für ganz Europa
- application/pgp-signature attachment: stored
- Next message: Ulf Wendel: "Re: [phplib] hidding template blocks"
- Previous message: Marko Kaening: "Re: [phplib] Problem with examples for template class"
- Next in thread: Jens Benecke: "[phplib] Re: PHPLIB suggestion for FORM elements & validation"
- Reply: Jens Benecke: "[phplib] Re: PHPLIB suggestion for FORM elements & validation"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]

