|
Posted by Andy Jeffries on 05/11/06 14:03
On Thu, 11 May 2006 11:02:38 +0000, Andy Jeffries wrote:
> On Wed, 10 May 2006 14:48:43 -0700, squash wrote:
>> sure you can use a flatfile. just pick a good delimeter to seperate the
>> names and comments. Then read in the file using file () and split each
>> line into an array using preg_split ( '/delimeter'/ ... then write out
>> the comments. forget mysql for such a simple thing.
>
> or use explode("delimited", $string) which will be quicker than
> preg_split.
And wouldn't have the downsides of having to ensure you avoid regular
expression special characters (for example, not that you would, but you'd
have an issue if you picked . as your separator).
Cheers,
Andy
--
Andy Jeffries MBCS CITP ZCE | gPHPEdit Lead Developer
http://www.gphpedit.org | PHP editor for Gnome 2
http://www.andyjeffries.co.uk | Personal site and photos
Navigation:
[Reply to this message]
|