This Example shows that how to remove empty or blank array from the given array.
For Example: - if you have an array whose one key is blank and you want to eliminate or remove this from the rest array. then you can use this example function in your project like it is: -
For Example: - if you have an array whose one key is blank and you want to eliminate or remove this from the rest array. then you can use this example function in your project like it is: -
function removeemptyarray($array)
{
foreach($array as $key=>$value)
{
if(!@$array[$key]['fieldname'])
{
unset($array[$key]);
}
}
return $array;
}
Thanks for Reading and Keep Visiting.
If you have any query related with Google Adsense, Blogging or Programming & Code then contact me through Contact form.
0 comments :
Post a Comment