PHPMailer - как включить дебаг откладку: различия между версиями

Материал из Wiki - Iphoster - the best ever hosting and support. 2005 - 2023
Перейти к:навигация, поиск
(Новая страница: «=== PHPMailer - как включить дебаг откладку === $mail->SMTPDebug = 2; $mail->isSMTP(); // tell the class to use SMTP $mail->SMTPAu...»)
 
 
(не показана 1 промежуточная версия этого же участника)
Строка 1: Строка 1:
 +
[[Файл:B_1.gif |link=https://bit.ly/3tbFsd6| Доступная цена]]
 +
 
=== PHPMailer - как включить дебаг откладку ===
 
=== PHPMailer - как включить дебаг откладку ===
  
  
 
+
  '''$mail->SMTPDebug = 4;'''
  $mail->SMTPDebug = 2;  
 
 
  $mail->isSMTP();  // tell the class to use SMTP
 
  $mail->isSMTP();  // tell the class to use SMTP
 
  $mail->SMTPAuth  = true;                /
 
  $mail->SMTPAuth  = true;                /

Текущая версия на 19:03, 21 сентября 2021

Доступная цена

PHPMailer - как включить дебаг откладку

$mail->SMTPDebug = 4; 
$mail->isSMTP();  // tell the class to use SMTP
$mail->SMTPAuth   = true;                /
$mail->Port       = 25;                 
$mail->Host       = "mail.yourhost.com"; 
$mail->Username   = "[email protected]"; 
$mail->Password   = "your password";     

Уровние откладки PHPMailer - от 1 до 4:

SMTP::DEBUG_OFF (0): Disable debugging (you can also leave this out completely, 0 is the default).
SMTP::DEBUG_CLIENT (1): Output messages sent by the client.
SMTP::DEBUG_SERVER (2): as 1, plus responses received from the server (this is the most useful setting).
SMTP::DEBUG_CONNECTION (3): as 2, plus more information about the initial connection - this level can help diagnose STARTTLS failures.
SMTP::DEBUG_LOWLEVEL (4): as 3, plus even lower-level information, very verbose, don't use for debugging SMTP, only low-level problems.