in reply to Can't rename
In addition to the suggestion about setting $a and $b to the full path to the file, you might also want to make sure that $ENV{DOCUMENT_ROOT} is really being set to what you are expecting it to be. Perhaps adding use strict or use warnings?
"Ex Libris un Peut de Tout"
update: I just got into work and skimmed my Perl book. From the docs, "rename will not (usually) work across filesystem boundaries, although on a Unix system, the mv command can sometimes be used to compensate for this." It goes on to add: "See the standard File::Copy module for cross-filesystem renames."
"Ex Libris un Peut de Tout"
|
---|
In Section
Seekers of Perl Wisdom