Re: [PHP] RegEx - Is this right?

2005-10-16 Thread Al Hafoudh

yes, it is equal, but i'd rather use file() function


Gustav Wiberg wrote:


Hi there!

I want to get conents of a file and split into a array...

   $s = file_get_contents($fileName);
   $splitS = preg_split(/\n/,$s);

Is this equal to using $splitS = file($fileName) ?

/G
http://www.varupiraten.se/



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



[PHP] RegEx - Is this right?

2005-10-15 Thread Gustav Wiberg

Hi there!

I want to get conents of a file and split into a array...

   $s = file_get_contents($fileName);
   $splitS = preg_split(/\n/,$s);

Is this equal to using $splitS = file($fileName) ?

/G
http://www.varupiraten.se/

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