Re: [SMARTY] no regexp ?
| From: | Katana | Date: | Mon, 03 Mar 2003 09:09:58 +0000 |
| Subject: | Re: [SMARTY] no regexp ? | ||
| References: | 1 | Groups: | php.smarty.general |
| Request: | Send a blank email to php-smarty-general+get-8336@lists.php.net to get a copy of this message | ||
pmcic> Hi,
pmcic> I didn't find in the doc any function that would
pmcic> allow to use regexp in a if statement for instance.
pmcic> I would like to do something like this:
pmcic> {if $myVar ereg "string"}
pmcic> do...
pmcic> {else}
pmcic> ...
pmcic> {/if}
As far as I know you can use any PHP Function within a if
statement:
{if ereg('string', $myVar)}