
March 25th, 2005, 02:27 PM
|
|
Registered User
|
|
Join Date: Mar 2005
Posts: 1
Time spent in forums: 2 m 59 sec
Reputation Power: 0
|
|
I found a few errors in the code:
PHP Code:
foreach ($structure->parts as $part) { // only save if an attachment if (isset($part->disposition) and ($part->disposition=='attachment'))<-- missing bracket { // open file $fp = fopen($part->ctype_parameters<-- this should really be d_parameters ['filename'], 'w'); // write body fwrite($fp, $part->body); // close file fclose($fp); } }
|