title: How to set the from name in php mailer?
body: <p>I can actually send the emails but I want to change the email <code>from name</code>. When I send emails, it comes into the receiver mailbox with my mail id. I want to change that to some other names. Kindly help me to do that. This is my code</p>
  
  <pre><code>    &lt;?php
      $mailto = $_POST['mail_to'];
      $mailSub = $_POST['mail_sub'];
      $mailMsg = $_POST['mail_msg'];
     require 'PHPMailer-master/PHPMailerAutoload.php';
     $mail = new PHPMailer();
     $mail -&gt;IsSmtp();
     $mail -&gt;SMTPDebug = 0;
     $mail -&gt;SMTPAuth = true;
     $mail -&gt;SMTPSecure = 'ssl';
     $mail -&gt;Host = "smtp.gmail.com";
     $mail -&gt;Port = 465; // or 587
     $mail -&gt;IsHTML(true);
     $mail -&gt;Username = "dkdev006@gmail.com";
     $mail -&gt;Password = "password";
     $mail -&gt;SetFrom("Kreatz.in");
     $mail -&gt;Subject = $mailSub;
     $mail -&gt;Body = $mailMsg;
     $mail -&gt;AddAddress($mailto);
     if(!$mail-&gt;Send())
     {
         echo "Mail Not Sent";
     }
     else
     {
         echo "Mail Sent";
     }
  </code></pre>