Hi Everyone ...
Hope everyone enjoying heading towards summer.
I've an array created by simplexml_load_file method which obviously store data in array of objects.
I want to delete some values(items) in array if a condition satisfy. and store the array in another array as object itself.
so, is there a way to delete one or more element in array of objects according to the condition supplied.
any clue will be appreciated.
thanks
object array
Moderator: General Moderators
- Christopher
- Site Administrator
- Posts: 13596
- Joined: Wed Aug 25, 2004 7:54 pm
- Location: New York, NY, US
Re: object array
You can use unset() or array functions like array_slice() to delete elements of an array. See the section in the manual about arrays.
(#10850)