PHPMailer::headerLine PHP Method

headerLine() public method

Format a header line.
public headerLine ( string $name, string $value ) : string
$name string
$value string
return string
    public function headerLine($name, $value)
    {
        return $name . ': ' . $value . $this->LE;
    }

Usage Example

 /**
  * Inherited phpMailer function adding a header to email message.
  * We override it to skip X-Mailer header.
  *
  * @param string $sName  header name
  * @param string $sValue header value
  *
  * @return null
  */
 public function headerLine($sName, $sValue)
 {
     if (stripos($sName, 'X-') !== false) {
         return;
     }
     return parent::headerLine($sName, $sValue);
 }
All Usage Examples Of PHPMailer::headerLine