in reply to What is wrong with my File open?
chdir "/" or die "Can't cd to /: $!"; my @dir = split /\//, $outputFileName; pop @dir; shift @dir; chdir $_ or die "Can't cd to [$_]: $!" for @dir; [download]