Re: Pattern Capture
| From: | Jason Wong | Date: | Tue, 13 Jan 2004 15:37:43 +0000 |
| Subject: | Re: Pattern Capture | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-174454@lists.php.net to get a copy of this message | ||
On Tuesday 13 January 2004 23:27, Cameron B. Prince wrote:
> Ok, I feel really lame for asking this, but I can I do this in PHP:
>
> $userid =~ /([\D]+)/;
> $baseName = $1;
>
> It seems like "Pattern Capture" is not the right term for the similar
> function in PHP. I'm not sure what to search for.
manual > Regular Expression Functions (Perl-Compatible) > Pattern Syntax
Then use preg_match() or preg_match_all().
--
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-general
------------------------------------------
/*
What GOOD is a CARDBOARD suitcase ANYWAY?
*/