Nested quantifiers in regex; marked by <-- HERE in m/([/|\.])?* <-- HERE
if($dat =~ /([\/|\.])?$_/i){
if($dat =~ /([\/|\.])?\Q$_\E/i){