Re: parser vs. regexp

From: Date: Sat, 16 Mar 2002 15:24:04 +0000
Subject: Re: parser vs. regexp
References: 1  Groups: php.smarty.general 
Request: Send a blank email to php-smarty-general+get-3103@lists.php.net to get a copy of this message
It might be that the curly braces are causing a problem with the parser. Have you tried a work around like \d\d\d\d instead of \d{4} ? Simon 'corecode' Schubert wrote: > > hello! > > could it be that something like this doesn't work because of the parser: > > {$foo|regex_replace:"/(\d{4})(\d{2})/":"\2.\1"} > > it always tries to use a function called "2" ;] > > i'll program an own modifier that does this, but... it's pretty ugly > that way. > > cheerz > corecode > > -- > /"\ http://corecode.ath.cx/ > \ / > \ ASCII Ribbon Campaign > / \ Against HTML Mail and News > > ------------------------------------------------------------------------ > Part 1.2Type: application/pgp-signature > > ------------------------------------------------------------------------ > --- > You are currently subscribed to smarty as: monte@ispi.net > To unsubscribe send a blank email to $subst('Email.Unsub') > Visit Smarty's homepage at > http://www.phpinsider.com/php/code/Smarty/

« previous php.smarty.general (#3103) next »