All pastes #409752 Raw Edit

Someone

public php v1 · immutable
#409752 ·published 2007-03-25 21:59 UTC
rendered paste body
The contents of $newArray[pathToFile] is a unix dir path, like /usr/local/bin for example.while ( $newArray = mysql_fetch_array ( $result ) ){  $a = array();  $b =& $a;  foreach (explode('/', trim($newArray[pathToFile], '/')) as $seg)  {    $b[$seg] = array();    $b =& $b[$seg];  }}?>