in reply to Regular expressions

In addition to previous mentions, you also need () around whatever you want to capture in the $1 variable.
if ($temp2 =~ m/^([a-zA-Z]+)$/) {$naam = $1;}

-jbWare