login about faq

Hello,

I saw that there's a "UnpackMHT" on the IOS side, anything similar for Linux, in Perl or Python? I found some sample Perl code using chilkat::CkMime();, but it didn't produce anything after setting the .mht filename and target directory in it, and produced no errors. The sample code I used is below.

Thanks,

  -Adam

!/apps/perlthreaded/bin/perl

use chilkat();

$mime = new chilkat::CkMime();

$success = $mime->UnlockComponent("Anything for 30-day trial."); if ($success == 0) { print "Failed to unlock component" . "n"; exit; }

Load a MIME document from a file:

(.mht and .eml files contain MIME).

$success = $mime->LoadMimeFile("./test.mht"); if ($success == 0) { print $mime->lastErrorText() . "rn"; exit; }

sa is a StringArray

$sa = $mime->ExtractPartsToFiles("/home/oracle/site"); if ($sa eq null ) { print $mime->lastErrorText() . "rn"; exit; }

$n = $sa->get_Count();

Display the filepaths of the files created:

for ($i = 0; $i <= $n - 1; $i++) { print $sa->getString($i) . "rn"; }

asked Jan 15 '16 at 13:22

avonnieda's gravatar image

avonnieda
11


The Chilkat API is essentially identical (other than syntax) across all programming languages and operating systems. The UnpackMHT method is available everywhere, including Linux.

link

answered Jan 18 '16 at 12:41

chilkat's gravatar image

chilkat ♦♦
12.7k317362463

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or __italic__
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Tags:

×21
×21
×19
×17

Asked: Jan 15 '16 at 13:22

Seen: 1,281 times

Last updated: Aug 19 '16 at 06:52

powered by OSQA