If you plan on using that directory as part of a filename, you could always give File::Spec a try. Not only will it do what you want by converting C:/windows to C:\windows, it helps you write portable code.
Which will output C:\temp\tempfileuse File::Spec; use strict; use warnings; my $dir = 'c:/temp'; my $file = 'tempfile'; my $path = File::Spec->catfile($dir, $file); print $path, "\n";
In reply to Re: change forward slash to backslash
by vek
in thread change forward slash to backslash
by Eric23
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |