open(TMP, ">$files_path/$tm-$i.$type") || error(...); print TMP "$fl"; close TMP;