06-10-2008, 12:26 PM
|
#2 (permalink)
|
|
Moderateur
Join Date: Apr 2007
Posts: 1,393
Thanks: 5
|
The third argument ( before_needle) is only available with PHP 5.3.0 and upward.
An equivalent snippet would be something like:
PHP Code:
$text2 = (FALSE !== ($pos = strpos($text0, '('))
? substr($text0, 0, $pos)
: FALSE;
|
|
|
|