Re: Regex error
| From: | Bas Jochems | Date: | Mon, 21 Jan 2002 16:49:52 +0000 |
| Subject: | Re: Regex error | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-81393@lists.php.net to get a copy of this message | ||
use
$rgTemp = split('[|]',$szTag);
instead of
$rgTemp = split("|",$szTag);
on line 2
PHP List wrote:
> Hi,
> Can someone please tell me why the this is happening:
>
> 1) $szTag = "test|3";
> 2) $rgTemp = split("|",$szTag);
> 3) $szTag = $rgTemp[0];
> 4) $nItemID = $rgTemp[1];
> ^line numbers for ref only, not in actual code.
>
> Will give me the error:
> PHP Warning: unexpected regex error(14) in /test.php on line 2
>
> What is an error 14 ?
>
> Thanks,
> Chris
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net
> For additional commands, e-mail: php-general-help@lists.php.net
> To contact the list administrators, e-mail: php-list-admin@lists.php.net