Jump to content

'message' 'comment' fields into something else to stop spammers?


Recommended Posts

Hi, I was told a preliminary way to stop some spammers in our forms was to
change the 'message' or 'comment' fields to an uncommon name.

So I tried this technique and all it did was keep in typed message in my form from showing in my email. For instance here is some simple code I tried. My 'message' field in the form area only looks like this when it is working. <textarea name="message" </textarea> and here is some php code when it works.

<?php
$headers .= "From: \" <".$from_address.">\n";
mail($message, $headers);
$from_address = "myemailaddress@myemailaddress";
$message = $_REQUEST['message'];
mail("myemailaddressagain", "Sent From Form", $message, $headers);
?>

So I changed all these message fields to 'post it' . Including this field.
$message = $_REQUEST['message']; into
$postit = $_REQUEST['postit'];

Like I said, all I get is an email without any message from the form when I change these fields. Can anyone explain this to me please? Thanks! [img src=\"style_emoticons/[#EMO_DIR#]/smile.gif\" style=\"vertical-align:middle\" emoid=\":smile:\" border=\"0\" alt=\"smile.gif\" /]
Thats it! Thanks!! [img src=\"style_emoticons/[#EMO_DIR#]/laugh.gif\" style=\"vertical-align:middle\" emoid=\":laugh:\" border=\"0\" alt=\"laugh.gif\" /] [!--quoteo(post=377256:date=May 26 2006, 04:13 AM:name=thorpe)--][div class=\'quotetop\']QUOTE(thorpe @ May 26 2006, 04:13 AM) [snapback]377256[/snapback][/div][div class=\'quotemain\'][!--quotec--]
You need to change this $_REQUEST['message'] to the same name as the form.
[/quote]
This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.