$email2);
require_once(’/homez.146/mobilo/www/limit/wp-content/plugins/wp-recaptcha/recaptchalib.php’);
require_once(’/homez.146/mobilo/www/limit/wp-content/plugins/wp-recaptcha/recaptchalib.php’);
// Register API keys at https://www.google.com/recaptcha/admin
$siteKey = „6Lfs8wATAAAAABI6KRnJgDwQDgV9I6zxE2s-tiGp”;
$secret = „6Lfs8wATAAAAANlTaoSiPABle96YM6btIP7NPJbL”;
// reCAPTCHA supported 40+ languages listed here: https://developers.google.com/recaptcha/docs/language
$lang = „pl”;
// The response from reCAPTCHA
$resp = null;
// The error code from reCAPTCHA, if any
$error = null;
$reCaptcha = new ReCaptcha($secret);
// Was there a reCAPTCHA response?
if ($_POST[„g-recaptcha-response”]) {
$resp = $reCaptcha->verifyResponse(
$_SERVER[„REMOTE_ADDR”],
$_POST[„g-recaptcha-response”]
);
}
$errorcaptcha=true;
if ($resp != null && $resp->success) {
$errorcaptcha=false;
}
$showform=$firsttime||$requirederror||$errorcaptcha||$emailerror;
$showsummary=!$showform;
?>
’;
else
print ’
„;
};
mysql_query(’SET NAMES \’utf8\”);
$Wynik=mysql_query($Sql);
//wczytaj zawartość formularza
$file=file_get_contents(’/homez.146/mobilo/www/mo-licenses/other_letterorder.html’);
$file = ReplaceTextValue($file,”%longprogramname%”,$longProgramName);
$file = ReplaceTextValue($file,”%name%”,$name);
$file = ReplaceTextValue($file,”%email%”,$email);
$file = ReplaceTextValue($file,”%street%”,$street);
$file = ReplaceTextValue($file,”%city%”,$city);
$file = ReplaceTextValue($file,”%postalcode%”,$postalcode);
$file = ReplaceTextValue($file,”%quantity%”,$quantity);
$file = ReplaceTextValue($file,”%total%”,$total);
$file = ReplaceTextValue($file,”%notes%”,$notes);
print ’
$topic=”=?UTF-8?B?”.base64_encode(„Zamówienie „.$longProgramName.” dla $email – „.htmlspecialchars_decode($name,ENT_QUOTES)).”?=”;
if(mail($email, $topic, $file, $headers))
{
echo „Dziękujemy za złożenie zamówienia. Na adres: $email został przesłany mail z informacjami widocznymi poniżej.”;
}
else
{
echo „nie udało się przesłać wiadomości email z hasłem. Spróbuj ponownie za chwilę.”;
}
}
else
print ’