function fileRelate($value, $suffix) { global $pdname; global $envData; $Tname =& $pdname[$suffix]; $Tname_val =& $Tname[$value]; if ($Tname != "" && $Tname_val == "") { $file_go = $envData[0][$suffix] . "/" . $value . "." . $suffix; $file_end = $envData[1][$suffix] . "/" . $value . "." . $suffix; $Tname_val = "false"; if (file_exists($file_go) && file_exists($file_end)) { $Tname_val = md5_file($file_go) == md5_file($file_end) ? "true" : "false"; } if ($suffix == "js") { jsRelate($value, $suffix); } } }
function jsMd5($value) { global $pdjsname; global $this_d; global $environment; $env = $environment[$_SESSION['env']]; $dev_js = $this_d . $env[0]['site'] . $env[0]['js'] . "/" . $value . ".js"; $test_js = $this_d . $env[1]['site'] . $env[1]['js'] . "/" . $value . ".js"; // echo ((md5_file($dev_js) == md5_file($test_js)?"true ":"false" )."----------".$value."<br>"); if (empty($pdjsname[$value])) { if (file_exists($dev_js) && file_exists($test_js)) { $pdjsname[$value] = md5_file($dev_js) == md5_file($test_js) ? "true" : "false"; } else { $pdjsname[$value] = "false"; } jsRelate($value); } }