Auto Inspection News:





   Copyright © 2005 Wellingborough England directory false; } if (!$success) { $smarty->assign ("filename", $filename); $smarty->assign ("main", "delete_file_message"); } } if ($REQUEST_METHOD=="POST" && $mode=="Upload") { if (file_exists ($root_dir.$dir."/$userfile_name")) { $success = false; $smarty->assign ("io_error", "1"); } else { if ($userfile_name == "none" || $userfile_name == "") { $success = false; $smarty->assign ("io_error", "1"); } else { if (!@copy ($userfile, $root_dir.$dir."/$userfile_name")) { $success = false; $smarty->assign ("io_error", "1"); }; } } if (!$success) { $smarty->assign ("filename", $userfile_name); $smarty->assign ("main", "upload_file_message"); } } if ($REQUEST_METHOD=="POST" && $mode=="Copy to") { if (file_exists ($root_dir.$dir."/$copy_file")) { $success = false; $smarty->assign ("io_error", "1"); } else { if (empty ($copy_file)) { $success = false; $smarty->assign ("io_error", "1"); } else { if (!@copy ($root_dir.$filename, $root_dir.$dir."/$copy_file")) { $success = false; $smarty->assign ("io_error", "1"); } } } if (!$success) { $smarty->assign ("filename", $copy_file); $smarty->assign ("main", "copy_file_message"); } } # # Browse directory tree mode # if ($success) { $maindir=$root_dir.$dir; if($dh = @opendir($maindir)) { while (($file = readdir($dh))!==false) if ($file!=".") $dir_entries[]=array("file"=>$file, "href"=>($file==".."?ereg_replace("\/[^\/]*$","",$dir):"$dir/$file"),"file_href"=>($root_url.$dir."/".$file),"filetype"=>filetype($maindir."/".$file)); closedir($dh); } $smarty->assign("dir_entries",$dir_entries); $smarty->assign("dir_entries_half",(int) (sizeof($dir_entries)/2)); $smarty->assign("main","edit_dir"); } } ?>