#!/usr/bin/perl use strict; use warnings; my $fullelementpath = "f:/_wo/haldane.txt"; if (-T $fullelementpath) {print "passed T\n";}else{print "failed for $fullelementpath\n";} # ----------------------- my $fullelementpath2 = "f:/_wo/haldane space.txt"; if (-T $fullelementpath2) {print "passed T\n";}else{print "failed for $fullelementpath2\n";}