Try this :
<?php
$foo = array('a','b','c');
unset($foo[1]);
print_r($foo); // [0] => a [2] => c
$bar = array('a','b','c');
$piece = array_splice ($bar, 1 ,1);
print_r($piece); // [0] => b
print_r($bar); // [0] => a [1] => c
?>
http://www.php.net/manual/en/function.array-slice.php
http://www.php.net/manual/en/function.unset.php
Regards,
Philip Olson
http://www.cornado.com/
On Thu, 15 Feb 2001, David Tandberg-Johansen wrote:
> How can I delete one record in a array?
>
> Example:
>
> $myarray = array ("a", "b", "c");
>
> I want to delete/take away "b" so the array is:
>
> $myarray = array ("a", "c");
>
> David
>
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]