safeTsurfa wrote: Before you go that way, why would you do such an unpleasant thing to your members? By displaying the member's email address as the username on all their posts, you are making them the victims of spammers, whose mail harvester bots will pick up these details and share them on the spammer network thanks to you. Not exactly a kind or friendly way to treat your board's membership, is it?
Then of course we get into the debate on whether you actually have any right to share personal data of that kind with the world at large, without first obtaining the explicit consent of the user, posting a very clear and prominent warning before sign up advising that you will share their mail addresses everywhere, etc, etc. Your proposal is kind of like me writing a letter to someone who then thinks that my act of writing somehow gives them a "right" to spread my home address all over the place, in defiance of applicable laws on data protection?
electronikus wrote: Well, you could use a form validation in javascript that checks the username-field for a correct e-mail adress.
Code: Select all
function Validatedetails($var, $type) {
trim($var);
if ($type=="name") { $Pattern = "^[A-Z][c]?[A-Z]?[a-z]+[a-z]$"; }
elseif ($type=="email") { $Pattern = "^([0-9a-z]+)([0-9a-z._-]+)@([0-9a-z._-]+)\.([0-9a-z]+)"; } elseif ($type=="phone") { $Pattern = "^([0-9]{3})-([0-9]{4})-([0-9]{4})"; }
$valid=ereg($Pattern, $var);
return $valid;
} # end of Function
Code: Select all
$valid=Validatedetails($email, "email");
Code: Select all
$valid=Validatedetails($email, "name");
Code: Select all
$valid=Validatedetails($email, "phone");