function send_mail($to,$subject,$message,$file = FALSE) { $from = 'mail@mail.ru'; $subject = '=?utf-8?b?'. base64_encode($subject) .'?='; $headers = "Content-type: text/plain; charset=\"utf-8\"\r\n"; $headers .= "From: <". $from .">\r\n"; $headers .= "MIME-Version: 1.0\r\n"; $headers .= "Date: ". date('D, d M Y h:i:s O') ."\r\n"; return mail($to,$subject,$message,$headers,'-f'.$from); }