Re: Replacement functions for array functions

From: Date: Sun, 16 Jul 2000 18:37:53 +0000
Subject: Re: Replacement functions for array functions
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-6836@lists.php.net to get a copy of this message
> The array functions were added in php4. > > Does somebody have replacement functions for php3 ? > > I need to use array_push en array_unshift ? As per the documentation, array_push() is the same as doing: $arr[] = "foo"; array_unshift() is a bit tougher in PHP 3. I'd suggest doing it by keeping track of your indices and just inserting a value with a lower index. -Rasmus

« previous php.general (#6836) next »