Results 1 to 2 of 2
Thread: Regular Expression?
May 29, 2002, 14:18 #1
This code isn't working properly. It should be searching for at least one occurrance of first lowercase letters, then uppercase letters, then a numeral. The alerts are just for debugging but I never see them. There are no errors reporting on the page either.
var strng = "The quick brown fox.";
if (!((strng.search(/(a-z)+/)) && (strng.search(/(A-Z)+/)) && (strng.search(/(0-9)+/))))
Sorry about the indents, couldn't figure out how to format the code in this boards editor.
May 31, 2002, 10:38 #2
- Join Date
- Feb 2002
- Gatwick, UK
- 0 Post(s)
- 0 Thread(s)
Sorry - should have answered this ages ago for you ... just didn't see it.
use string.match(regex) - if that doesn't work - post again - i'll fix what you have.
Flawless---=| If you're going to buy a pet - get a Shetland Giraffe |=---