On Mon, 27 May 2002, Jonas Hörnblad wrote:
> Hi there,
> I've only been PHPing for some week and ofcours I've ran into my first two
> 1. I'm building this community thing and I have a text file with the users
> that is currently logged in. When they press logout there name is deleted
> from the textfile, but if they just close there browser or surf to another
> site there name is still in the text-file until they log out next time. Any
> ideas how to avoid this?
Dump the text file and use sessions. Will make your life easier and they provide easy
solutions to problems like "logout".
> 2. How do I sort an array? I've tried array_multisort(); but I can only
> "ascci-sort" my array which makes R come before j and so on. How do I sort
> alphabeticly and not case sencetive ascci?
There are plenty of XXsort() functions in the manual (hint!hint!). Your case needs
Or you can do it manually with usort() and implement your own comparision function.
> MSN Photos is the easiest way to share and print your photos:
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php