Whoops.. I missed one bit. Rasmus did it right. ;)

On Wed, 30 Oct 2002 [EMAIL PROTECTED] wrote:

> If I understand you correctly, I think you want this?
> 
> $matches = array();
> $test = "(this)example";
> preg_match("/\((.*)\)(.*)/", $test, $matches);
> array_shift($matches);
> 
> On Wed, 30 Oct 2002, Simon Dedeyne wrote:
> 
> > I have a little question. I'm having some difficulty with regular
> > expressions:
> >  
> > here it is:
> > (this)example
> > should be output in an array
> > [0]=> this
> > [1]=> thisexample
> >  
> > I'm supposing this should be done with preg_grep, but I'm not really
> > familiar with some of it's syntax for the regular expression.
> > I could use some ideas,
> >  
> >  
> > cheers,
> > Simon
> >  
> > 
> 
> -- 
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
> 
> 

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to