PHP
Chilkat2 PHP
Load MIME Object from Email Object
See more Email Object Examples
Demonstrates how to load a Chilkat Mime object from a Chilkat Email object. (Copies the email into a Mime object.)Chilkat PHP Downloads
<?php
use Chilkat2\Email;
use Chilkat2\Mime;
use Chilkat2\StringBuilder;
$email = new Email();
$email->LoadEml('qa_data/eml/sample.eml');
// Write the full MIME of the email to a StringBuilder.
$sbMime = new StringBuilder();
$email->GetMimeSb($sbMime);
// Load the MIME object from the StringBuilder
$mime = new Mime();
$mime->LoadMimeSb($sbMime);
echo $mime->GetMime(), "\n";