📜  php 数组递归删除空值 - PHP 代码示例

📅  最后修改于: 2022-03-11 14:53:48.630000             🧑  作者: Mango

代码示例4
array_filter(explode('/', '/home/teste sdsd/   /'), 'trim');
//Result
[
     1 => "home",
     2 => "teste sdsd",
]

//-----------
array_filter(explode('/', '/home/teste sdsd/   /'), 'strlen')
//Result
  [
     1 => "home",
     2 => "teste sdsd",
     3 => "   ",
   ]