Hi,
Can you see, just from the highlighting, that something's gone awry?
I would suggest that you 'unpack' the code a little to find out where the error lies.
<?php
$first_name = stripslashes(trim($_POST['first_name']));
$regex = '^[[:alpha:]\.\';
$match = preg_match($regex, $first_name);
if(strlen($first_name)>=2 && strlen($first_name<=15) && !$match){
$fn = escape_data($first_name);
} else {
$fn = FALSE;
echo '<p><font color="red">Please enter your first name!</font></p>';
}
?>
You can now see straightaway that the problem is that the regex string doesn't end with a quote.
Paul.