static function check_file( $path, $w = false, $isdir = false ){
	 	$strtype = $isdir ? 'Directory' : 'File'; 
		if( !file_exists($path) ){
			trigger_error("$strtype not found; `$path'", E_USER_NOTICE );
			return false;
		}
		if( $isdir && !is_dir($path) ){
			trigger_error("Not a directory; `$path'", E_USER_NOTICE );
			return false;
		}
		if( !$isdir && !is_file($path) ){
			trigger_error("Not a file; `$path'", E_USER_NOTICE );
			return false;
		}
		if( !is_readable($path) ){
			trigger_error("$strtype not readable by `".trim(`whoami`)."'; `$path'", E_USER_NOTICE );
			return false;
		}
		if( $w && !is_writeable($path) ){
			trigger_error("$strtype not writeable by `".trim(`whoami`)."'; `$path'", E_USER_NOTICE );
			return false;
		}
		return true;
	 }