" . ((isset($output[$module])) ? ' ' : "$module" ) . " | $dup | $other_module | $compare | ";
break;
default:
$output[$dup][] = "$dup | $module | $other_module | $compare |
";
break;
}
}
}
}//var_dump($output);
echo "By Key By Module
Equal: $equal, Differ in case only: $case, differ in content: $diff
";
switch ($mode)
{
case 'module':
echo "Key | First File | Second File | Difference |
";
foreach ($output as $module => $html)
{
echo implode('', $html);
}
break;
default:
ksort($output);
echo "File | Key | Conflicting File | Difference |
";
foreach ($output as $dup)
{
echo implode('', $dup);
}
break;
}
echo "
";
function find_modules($dirname)
{
$list = glob("$dirname/*.php");
foreach(glob("$dirname/*", GLOB_ONLYDIR) as $name)
{
$list = array_merge($list, find_modules($name));
}
return $list;
}
?>