That unset will not do what you want it to do. You need one of the following:
// To preserve keysunset($names[1]);// It is now => [0 => 'Mike', 2 => 'Paul']// or to change keysarray_splice($name,1,1);// It is now => [0 => 'Mike', 1 => 'Paul']
Businessman and blogger #Javascript, #Python and #PHP. My favorite frameworks/librairies are #React, #Laravel, and #Django. I am also a fan of #TailwindCSS
That
unset
will not do what you want it to do. You need one of the following:Did not know that one... Thanks for the tips!