Export
$value)
{
$path = realpath($dir . DIRECTORY_SEPARATOR . $value);
if (is_dir($path))
{
$result[$value] = dirToArray($path);
}
else
{
if (substr($value, -3) == '.js')
{
if (!in_array($value, $fileIgnore))
{
$index = str_replace($src, "", $path);
$index = substr($index, 1);
$result[substr($value, 0, -3)] = $index;
}
}
}
}
return $result;
}
function displaySection($title, $files) {
if ($title === "")
{
echo "Phaser v2.1.1
";
}
else
{
echo "$title
";
}
echo "";
foreach ($files as $name => $file)
{
if (is_array($file))
{
displaySection($name, $file);
}
else
{
echo "- $name";
// echo " [ json ]
";
echo " [ json ]";
}
}
echo "
";
}
$src = realpath('../src');
$files = dirToArray($src);
displaySection("", $files);
// echo "";
// var_dump($src);
// print_r($files);
// echo "
";
?>