yay. 

this preg business methinks needs some more looking into. ;) everywhere
I've looked theres always one or 2 people proselytizing its greatness.

my late-night "boredom" reading of O'Reilly's _Perl_ (sans computer or
pause) left little behind little information in my head, not surprisingly.

Thanks much, sir.

        --kevin



On 21 Aug 2001 [EMAIL PROTECTED] wrote:

> Kevin Keeler <[EMAIL PROTECTED]> wrote:
> > $entry_hidden = eregi_replace("<hide>.+</hide>","<hidden>",$entry);
> 
> try: $entry_hidden = preg_replace("|<hide>.+?</hide>|i","<hidden>",$entry);
> 
> ".+" is 'greedy', meaning it consumes as much as text as it can. with
> perl-like regular expressions, you can add a trailing "?" which makes
> the + and * operators non-greedy.
> 
> jim
> 
> -- 
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
> 


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to