this is my code:
<?php
functionrequire 'zMovie/phpmailer/PHPMailerAutoload.php';
$mail = new PHPMailer;
$mail->isSMTP(); // Set mailer to use SMTP
$mail->Host = 'smtp.live.com'; // Specify main and backup SMTP servers
$mail->SMTPAuth = true; // Enable SMTP authentication
$mail->Username = '[email protected]'; // SMTP username
$mail->Password = 'Teresapaula1'; // SMTP password
$mail->SMTPSecure = 'tls'; // Enable TLS encryption, `ssl` also accepted
$mail->Port = 587; // TCP port to connect to
$mail->setFrom('[email protected]', 'Mailer');
$mail->addAddress('[email protected]', 'Fernando Alves'); // Add a recipient
$mail->addAddress('[email protected]'); // Name is optional
$mail->addReplyTo('[email protected]', 'Information');
$mail->addCC('[email protected]');
$mail->addBCC('[email protected]');
$mail->addAttachment('/var/tmp/file.tar.gz'); // Add attachments
$mail->addAttachment('/tmp/image.jpg', 'new.jpg'); // Optional name
$mail->isHTML(true); // Set email format to HTML
$mail->Subject = 'Here is the subject';
$mail->Body = 'This is the HTML message body <b>in bold!</b>';
$mail->AltBody = 'This is the body in plain text for non-HTML mail clients';
if(!$mail->send()) {
echo 'Message could not be sent.';
echo 'Mailer Error: ' . $mail->ErrorInfo;
}
else {
echo 'Message has been sent';
}
Im PHP-Mailer mit meiner Form senden und E-Mail Throught aber, dass Fehler meiner nerves.im 1 Tag pushen dieses Projekt zu beenden und ich nicht lösen kann dies !! Er sagte auch, dass der Fehler in Zeile 2 "functionrequire 'zMovie/phpmailer/PHPMailerAutoload.php';". Wenn Sie alle mir helfen könnten, wäre ich Mutch Dankbar !! :)T_CONSTANT_ENCAPSED_STRING
Was zum Teufel ist 'functionrequire'? – tkausl
Funktion aus Funktionsanforderung entfernen 'zMovie/phpmailer/PHPMailerAutoload.php'; – Satya
aber wenn ich Funktion entferne, gibt es dieses "Warnung: erfordern (zMovie/phpmailer/PHPMailerAutoload.php) [function.require]: konnte Strom nicht öffnen: Keine solche Datei oder Verzeichnis in C: \ Benutzer \ Nazista \ Desktop \ soft \ www \ zMovie \ contact.php on line 2 Schwerwiegender Fehler: require() [function.require]: Fehler beim Öffnen von 'zMovie/phpmailer/PHPMailerAutoload.php' (include_path = '; C: \ Users \ Nazista \ Desktop \ soft \ php5 ') in C: \ Benutzer \ Nazista \ Desktop \ soft \ www \ zMovie \ contact.php in Zeile 2 " –