Re: Split

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

First, read the help of 'preg_replace' at php.net.

Second: try this: preg_split('/\//',$sPath,$iMax)
Third: use explode: explode('/',....)

Cheers,

        Tamas



2011.12.13. dátummal, 21:33 időpontban Jack <JackListMail@xxxxxxxxx> írta:

> OK so I have seen enough errors about split, so I decided to update my code:
> 
>  return split("/", $sPath, $iMax);
> 
> 
> 
> I tried:
> 
> return preg_split("/", $sPath, $iMax);
> 
> return preg_split("/", $sPath, $iMax, PREG_SPLIT_DELIM_CAPTURE);
> 
> 
> 
> and a few other combinations, in the end always with errors. not sure I get
> the additional aspect.
> 
> I do see ther error log it tells me no ending delimiter
> 
> 
> 
> Any help appreciated.
> 
> 
> 
> 
> 
> Thanks!
> 
> Jack
> 
> 
> 

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux