Your IP : 18.219.192.243


Current Path : /data/web/virtuals/51568/virtual/www/www/letniskola/
Upload File :
Current File : /data/web/virtuals/51568/virtual/www/www/letniskola/mail.php

<?php
use PHPMailer\PHPMailer\PHPMailer;
use PHPMailer\PHPMailer\Exception;

require '/var/www/web.gymzn.cz/public_html/vendor/PHPMailer/src/Exception.php';
require '/var/www/web.gymzn.cz/public_html/vendor/PHPMailer/src/PHPMailer.php';
require '/var/www/web.gymzn.cz/public_html/vendor/PHPMailer/src/SMTP.php';

   $mail = new PHPMailer();
   $mail->IsSMTP();
   $mail->Mailer = "smtp";
   $mail->setLanguage('cs');
   $mail->CharSet = PHPMailer::CHARSET_UTF8;     
   $mail->SMTPDebug  = 0;  
   $mail->SMTPAuth   = TRUE;
   $mail->SMTPSecure = "tls";
   $mail->Port       = 587;
   $mail->Host       = "wes1-smtp.wedos.net";
   $mail->Username   = "mailer@zsrepubliky.cz";
   $mail->Password   = "Mail*er*2022";
   $mail->SetFrom("mailer@zsrepubliky.cz", "Mailer zsrepubliky.cz");
   $mail->isHTML(TRUE);

   
   $mail->Subject = 'Požadavek na schválení platby';   
   $bodyX = 'Pokusný text';
 
     $mail->Body = $bodyX;
     $mail->AltBody = strip_tags($bodyX);
     try {
       $mail->addAddress('dvorak@gymzn.cz');

    $mail->send();
    echo "odesláno ... $radek->STUDENT<br>";    
    }
    catch (Exception $e)
    {
       echo $e->errorMessage();
    }
    catch (\Exception $e)
    {
       echo $e->getMessage();
    }

   
    

?>