Delete row from php array
yes. i would have made it shorter, but need at least 30- charcters. so here you go:
unset($data[2]);
The above answers work. But here is what i got from the site listed below. I think its cool.
//deletes a number on index $idx in array and returns the new array
function array_delete($idx,$array) {
unset($array[$idx]);
return (is_array($array)) ? array_values($array) : null;
}
http://dev.kafol.net/2009/02/php-array-delete.html