#!/Perl
print "$0 ... Hello, World...\n";
my $tvar = "Links\\FIFA World Cup™ - Tournament -"; 
print "$tvar\n";
my $var = 'Cup™ -';
my $sch = '™';
my $len = length($var);
my $ind = rindex($tvar, "\\");
my $fold = 'unknown';
my $tit = $tvar;
if ($ind != -1) {
	$fold = substr($tvar, 0, $ind);
	$tit = substr($tvar, $ind + 1);
}
print "Folder is [$fold], title is [$tit] ...\n";
for (my $i = 0; $i < $len ; $i++) {
	my $ch = substr($var,$i,1);
	##if ($ch == 0x99) {
	if ($ch eq $sch) {
		print "got [$ch] 0x99 ...\n";
	} else {
		print "got [$ch] ...\n";
	}
}
$var =~ s/$sch/&153/g;
print "New var [$var]\n";
