Skip to content

Instantly share code, notes, and snippets.

@danielstrelec
Created January 31, 2020 09:33
Show Gist options
  • Save danielstrelec/1adb3c6a1a3bbc56de438840531e9177 to your computer and use it in GitHub Desktop.
Save danielstrelec/1adb3c6a1a3bbc56de438840531e9177 to your computer and use it in GitHub Desktop.
<?php
// zasílání e-mailů přes SMTP bez pluginu
function wt_smtp( PHPMailer $mail ) {
$mail->Host = 'smpt.server';
$mail->Port = 465;
$mail->SMTPSecure = 'tls';
$mail->Username = 'jmeno';
$mail->Password = 'heslo';
$mail->SMTPAuth = true;
$mail->IsSMTP();
}
add_action( 'phpmailer_init', 'wt_smtp' );
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment