Dave Fischetti wrote:
> WOW alex. I KNEW their had to be a different and MUCH BETTER way to do
> this.
> Now if I wanted to move the file from the /tmp folder to say an images
> directory or even into the database itself, Can I do that within the
> loop. or does it have to happen sooner before its parsed?
It should happen before the script ends, because the /tmp files created
by the parser are deleted then. So in the loop is the perfect place:
<code>
// ...
if ( get_class( $part ) === 'ezcMailFile' )
{
echo "Attachment: " . $part->fileName;
copy( $part->fileName, '/home/images/' . basename(
$part->fileName ) ); // or to database
}
</code>
--
Alexandru Stanoi
eZ Components System Developer
eZ Systems | http://ez.no
--
Components mailing list
[email protected]
http://lists.ez.no/mailman/listinfo/components