Trezz
12-03-02, 11:46
| Hi, I'm a newbie and have a problem with a surfer who is getting his giggles from submitting invalid e-mail addy's to my email form. Once the email is submitted the surfer is taken to a d/l page. The d/l page is written in php, so even though you can bookmark the d/l page, if you return without submitting an email addy, it returns an error. So one must gain access via the e-mail form page. Problem is this joker is taking up to 10 - 15 d/l of the file each day ( 260KB) work that out over a month & it turns into a major pain in the butt. To stop this I have tried detering this surfer with a echo of his IP addy on the d/l page & have given notice of this action under the e-mail form, however after a few days, its started again. Is there any way I can incorporate an e-mail syntax check - via the submitted domain's smtp mailserver, to see if this is a valid email addy? emails being submitted are like : wdgwndge@verio.net & so on. I have searched high & low,although I have found a couple for ASP have been unable to find for php. Any assistance on this is greatly appreciated, thank you :) // define some settings $to = "xxxxx@xxxxx.com" ; $from = "xxxxx@xxxxx.com"; // make sure everything is filled in if (!strlen($_POST["email"])) die("You did not enter your e-mail!"); // construct the body $body = "Name: $_POST[email]\n\n "; // send the email mail($to, $_POST["subject"], $body, "From: $to"); |