\r\n"; // next include a replyto $headers .= "Reply-To: " . $_POST["eMail"] . "\r\n"; // often email servers won't allow emails to be sent to // domains other than their own. The return path here will // often lift that restriction so, for instance, you could send // email to a hotmail account. (hosting provider settings may vary) // technically bounced email is supposed to go to the return-path email $headers .= "Return-path: " . $_POST["eMail"]; // now we can add the content of the message to a body variable $body = "Ime podjetja: " . $_POST["name"] . "\r\n" . "Ulica: " . $_POST["address"] . "\r\n" . "Poštna številka in kraj: " . $_POST["city"] . "\r\n" . "Država: " . $_POST["state"] . "\r\n" . "Dejavnost podjetja: " . $_POST["activity"] . "\r\n" . "Kontaktna oseba: " . $_POST["contactPerson"] . "\r\n" . "Telefon: " . $_POST["phone"] . "\r\n" . "Telefaks: " . $_POST["fax"] . "\r\n" . "E-pošta: " . $_POST["eMail"] . "\r\n" . "ZANIMAM SE ZA! Nova oprema: " . $_POST["message"] . "\r\n" . "Želim prejemati brezplačni katalog Lesnine inženiring 'Zastopniški program strojne opreme' z 'Borzo rabljene opreme'! " . $_POST["wishToReceive"] ; // once the variables have been defined, they can be included // in the mail function call which will send you an email $header_ = 'MIME-Version: 1.0' . "\r\n" . 'Content-type: text/plain; charset=UTF-8' . "\r\n"; mail($sendTo, '=?UTF-8?B?'.base64_encode($subject).'?=', $body, $header_ . $headers); ?>