Hi All,
I am after a bit of help with a Captcha spam protection box.
The site gave me instructions, and all is well, apart from if the user give the wrong Captcha information...
The highlighted code is the part where i would like help, i would like the error message to appear in the same area/under submit button, in the form. For example: "*Wrong input for Captcha ", not take the user to a new screen, and make them hit the back button.
ANY help would be greatly appreciated, as im very new to PHP and not really sure whats what.
The code is:
***** PLEASE THE CODE TAG WHEN POSTING SOURCE CODE *****Line number On/Off | Expand/Contract<?phprequire_once('recaptchalib.php');$privatekey = "************************";$resp = recaptcha_check_answer ($privatekey, $_SERVER["REMOTE_ADDR"], $_POST["recaptcha_challenge_field"], $_POST["recaptcha_response_field"]); [color=#0000FF]if (!$resp->is_valid) { die ("The reCAPTCHA wasn't entered correctly. Please go BACK and try again..." . "(reCAPTCHA said: " . $resp->error . ")");}[/color] $to = "grant@********";$subject = "Enquiry";$name = $_REQUEST['name'] ;$phone = $_REQUEST['phone'] ;$email = $_REQUEST['email'] ;$message = $_REQUEST['message'] ;$headers = "From: $email";$body = "Enquiry From: $name.nn$name's Phone Number: $phone.nnEnquiry:n$message";$sent = mail($to, $subject, $body, $headers) ;if($sent){header( 'Location:******** TEST_ENVIRONMENT/Tatar/thank_you.php' ) ;}else{print "We encountered an error sending your enquiry"; }?>
Thank you in advance
first few characters only
hi, does anyone know how to use PHP to take the first few words of a text and limit them? i have seen this in many news sites where the news story headline reads like "woman found in obama's
Help? Need help on project with templates involving mysql and php.
I'm having a hard time explaining what I want but basically here is what I have in place:-Database with 500 members signed up and using under a table called 'users'-Php page that people click a link
MII Netweaver Server stopped due to CPIC connection Problem
Dear Experts,
Add User script "Could not execute query"
This should be an easy script but I can't get it to run. Can someone please help me?<html><head><title>Adding a
Display search result
Hi!I have a SQL database with information about albums and track (music). This is where the user inputs a search term(entersearch.php): Code: <form name="form"
PHP page loading in Firefox but not in IE
hello,i am currently doing a project in PHP and i have a problem. If I view the project in Mozilla Firefox it works fine but if i open using IE i am having problem with the design which is not getting
Storing user data help?
Hey Guys, I'm not use if this question is to broad but I can always give you more information if needed.I have a website where users can login which uses mysql anyway I have a little form asking some
Query failed issue with php script but works fine in mssql manager!
hi i have the script below which copies data from one table to another but will only insert new data update current data or delete old data from tempproducts to products then it will delete the
PHP, Arrays & A Lot Of Confusion
I've been doing basic PHP work on sites for a few years now, but I've never been tempted to learn how the ARRAY function worked, nor in what instances to use it. Now I've stumbled upon the jCarousel
Set Categories
I am creating a submission form for somebody to come in and submit products. These products are separated by brand. How can I get them to display according to the brand?Here is the form code:Code: