You are here: Re: Sort array from .dat file « PHP Programming Language « IT news, forums, messages
Re: Sort array from .dat file

Posted by Janwillem Borleffs on 07/17/07 20:33

Dan R. wrote:
> I'm using the following to open and print values from a .dat file but
> I can't figure out how to sort the results. I think I need to use
> either the array_multisort() or krsort() functions. If so, how would I
> do that?
>

No matter which function you use, you will have to create the array before
you can apply it. Immediately, performance will be an issue when files get
bigger.

The best thing in this case (besides using a database) is to sort the data
while writing to the file. Performance will then be less of an issue, since
you could make the process asynchrone. When the file is already sorted, all
you have to do is displaying its contents.


JW

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация