title: phpmailer not showing images in html
body: <pre><code>&lt;?php
  session_start();
  include "connections/db.php";
  use PHPMailer\PHPMailer\PHPMailer;
  use PHPMailer\PHPMailer\Exception;
  $date = date("Y-m-d H:i:s");
  $Email = $_POST['email1'];
  $link = $_POST['link1'];
  include "SMTP.php";
  require 'phpmailer/vendor/autoload.php';
  include 'PHPMailer.php';
  $mail = new PHPMailer(true);
  $mail-&gt;SMTPDebug = 0;
  $mail-&gt;isSMTP();
  $mail-&gt;Host = 'smtp.gmail.com';
  $mail-&gt;SMTPAuth = true;
  $mail-&gt;Username = '********@gmail.com';
  $mail-&gt;Password = 'owais@1';
  $mail-&gt;SMTPSecure = 'tls';
  $mail-&gt;Port = 587;
  $mail-&gt;setFrom('inboxowaislatif@gmail.com', 'Cloud Asset, Oy');
  $mail-&gt;addAddress($Email, 'Cloud Asset, Oy');
  $mail-&gt;Subject = 'Download pdf';
  $mail-&gt;Body =
      '
  &lt;style&gt;
  body
  {
  background-color:blue;
  }
  &lt;/style&gt;
  &lt;body style="background-image: url(http://88.194.145.207:8882/p3-fi/bgimage.jpg); background-repeat: no-repeat;  background-position: center; background-size: cover;"&gt;
  &lt;div style="height:70px;"&gt;&lt;/div&gt;
  &lt;div style="background-image: url(http://88.194.145.207:8882/p3-fi/bgimage.jpg); background-repeat: no-repeat;  background-position: center; background-size: cover;"&gt;&lt;/div&gt;
  &lt;div style="
      display: flex;
      /* Or whatever */
  
  "&gt;
      &lt;img src="http://88.194.145.207:8882/p3-fi/logo.png" style="
  
      margin: auto;
      "/&gt;
  &lt;/div&gt;
  &lt;div style="height:30px; "&gt;&lt;/div&gt;
  &lt;div style="width:50%; height:200px; display:flex; margin:auto; background-image: url(http://88.194.145.207:8882/p3-fi/image2.jpg);  background-repeat: no-repeat;  background-position: center; background-size: cover;"&gt;
  
  &lt;a href="http://88.194.145.207:8882/p3-fi/' .
      $link .
      '" style="text-align:center; margin:auto;"&gt;&lt;img src="http://88.194.145.207:8882/p3-fi/download.png" style="margin:auto; border-radius:100px; cursor:pointer;" /&gt;&lt;/a&gt;&lt;br&gt;&lt;br&gt;
  
  &lt;/div&gt;
  &lt;div style="width:50%; height:50px; margin:auto; background-image: url(http://88.194.145.207:8882/p3-fi/image2.jpg);  background-repeat: no-repeat;  background-position: center; background-size: cover;"&gt;
   &lt;h3 style="color:white; text-align:center; margin:0px;"&gt;&lt;a href="http://88.194.145.207:8882/p3-fi/' .
      $link .
      '" style="color:white; text-decoration:none;"&gt;DOWNLOAD FILE&lt;a/&gt;&lt;/h3&gt;
  &lt;/div&gt;
  &lt;div style="width:50%; margin:auto; background-color:white;"&gt;
  
    &lt;h3 style="margin:0px; padding-left:30px; padding-right:30px; padding-top:30px; Text-align:center;"&gt;P3 SME digital POS for banks,&lt;br&gt;Ready To download&lt;/h3&gt;
    &lt;p style="padding:20px; text-align:center; margin:0px;"&gt;Lorem ipsum dolor sit amet, consectetur adipiscing elit. In congue arcu a posuere mattis. Integer mollis eleifend lorem id sodales. Duis sollicitudin diam enim,&lt;/p&gt;
  
  
  &lt;/div&gt;
  &lt;div style="width:50%; margin:auto; position:relative; text-align:center; background-color:white; height:100px; "&gt;
    &lt;button style="background-color:#2C15D9; margin-top:25px;  color:white; border-color:blue; border-radius:100px; width:150px; height:30px;"&gt;&lt;b&gt;GET NOW&lt;/b&gt;&lt;/button&gt;
  &lt;/div&gt;
  &lt;div style="width:50%; margin:auto; background-color:white; display:flex;"&gt;
  &lt;table align="center" style=""&gt;
      &lt;tr style="margin:0px;"&gt;
       &lt;td style="padding:10px;"&gt;&lt;img src="http://88.194.145.207:8882/p3-fi/facebook.png" style="width:20px; height:20px;"/&gt;&lt;/td&gt;
           &lt;td style="padding:10px;"&gt;&lt;img src="http://88.194.145.207:8882/p3-fi/twitter.png" style="width:20px; height:20px;"/&gt;&lt;/td&gt;
           &lt;td style="padding:10px;"&gt;&lt;img src="http://88.194.145.207:8882/p3-fi/instagram.png" style="width:20px; height:20px;"/&gt;&lt;/td&gt;
           &lt;td style="padding:10px;"&gt;&lt;img src="http://88.194.145.207:8882/p3-fi/youtube.png" style="width:20px; height:20px;"/&gt;&lt;/td&gt;
               &lt;td style="padding:10px;"&gt;&lt;img src="http://88.194.145.207:8882/p3-fi/google.png" style="width:20px; height:20px;"/&gt;&lt;/td&gt;
      &lt;/tr&gt;
    &lt;/table&gt;
  &lt;/div&gt;  
  &lt;div style="width:50%; margin:auto; background-color:white; height:50px;"&gt;&amp;nbsp;&lt;/div&gt;    
  &lt;div style="height:30px;"&gt;&lt;/div&gt;
  &lt;p style="text-align:center; color:white;"&gt;@2018 P3 by CloudAssest&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;a href="#" style="color:white;"&gt;&lt;u&gt;Unsubscribe&lt;/u&gt;&lt;/a&gt;&lt;p&gt;
  &lt;/body&gt;
  
  ';
  $mail-&gt;AltBody = 'This is the body in plain text for non-HTML mail clients';
  //$mail-&gt;AddAttachment($link);
  if ($mail-&gt;send()) {
      $query = "insert into users (user_email,date,download_pdf) values ('$Email','$date','$link')";
      $run = mysqli_query($mysqli, $query);
      if ($run) {
          $_SESSION['username'] = $Email;
          echo "Email send successfully";
      }
  }
  ?&gt;
  </code></pre>
  
  <p>Hello Every one,
    I am using php mailer for sending emails with a template. It is working perfectly with using gmail but when i tested it in outlook no images are being show the code above is working perfectly with gmail.</p>
  
  <p>The image below is for gmail:</p>
  
  <p><img src="https://i.stack.imgur.com/etx5t.png" alt="enter image description here"></p>
  
  <p>This image is for outlook:</p>
  
  <p><img src="https://i.stack.imgur.com/IWbOl.png" alt="enter image description here"></p>