I want to send e-mails to multiple persons in a while loop using PHPmailer. But as soon as the loop gets to the row include '../email/PHPMailerAutoload.php';
it stops inside the while loop. The full code looks like this
<?php
$result = $con->prepare('SELECT * from table WHERE Date = ?');
$result->execute([$Date]);
while($row = $result->fetch(PDO::FETCH_BOTH)){
$Email=$row['Email'];
include '../email/PHPMailerAutoload.php';
email_function($Email);
}
?>
Any ideas?