Still REG EX

From: Date: Sun, 24 Mar 2002 00:33:31 +0000
Subject: Still REG EX
Groups: php.general 
Request: Send a blank email to php-general+get-89867@lists.php.net to get a copy of this message
I'm still playing about trying to validate an url www(dot)something(dot)something ! I thought this would work but know if (ereg("^(w{3})(\\.)([a-zA-Z]+)(\\.)([a-z]{2,4})$", $str)) can anyone explain why not ??? ^(w{3}) = three w at start of string ?? (\\.) = literal dot ?? ([a-zA-Z]+) match any word with letters ?? (\\.) = literal dot ?? ([a-z]{2,4})$ = at least 2 leters eg de but upto 4 eg info but it doesn't ! thanks in advance john

« previous php.general (#89867) next »