Re: Wrong Parament count

From: Date: Wed, 22 Oct 2003 08:22:52 +0000
Subject: Re: Wrong Parament count
References: 1 2  Groups: php.db 
Request: Send a blank email to php-db+get-31255@lists.php.net to get a copy of this message
On Wednesday 22 October 2003 16:15, Jason Wong wrote: > $input_string = "#ircchannel"; > if (preg_match("/^#[a-zA-Z]+/", $input_string) { > echo "Looks like an irc channel"; } > else { > echo "Go check your input"; > } Sorry that regex should look like: if (preg_match("/^#[a-zA-Z]+$/", $input_string) { -- Jason Wong -> Gremlins Associates -> www.gremlins.biz Open Source Software Systems Integrators * Web Design & Hosting * Internet & Intranet Applications Development * ------------------------------------------ Search the list archives before you post http://marc.theaimsgroup.com/?l=php-db ------------------------------------------ /* The problem that we thought was a problem was, indeed, a problem, but not the problem we thought was the problem. -- Mike Smith */

« previous php.db (#31255) next »