
Hi Martin, thank you for your help. I think, reading the content is possible with open(FILE, <, file.pdf) while(<FILE>) { $content = $_; } close(FILE); Am I right? If so I think everything is fine now ;-) Best regards Marco Martin Edenhofer schrieb:
Hi Marco,
a file/path of a file in your file directory is not possible. You need to read the content at first, then you can put the content into the OTRS function.
Filename means: The filename of the attachment which is shown to the email receiver. You as coder need to define this. May be in your case the same file name as the file in your file system. Content means: The content of the attachment as string. ContentType means: The content type of the attached file. You as coder need to decide what content type do you send. For pdf you need to put application/pdf in there. :)
Any more questions? :)
-Martin
On Apr 19, 2008, at 15:39 , Marco Rudzuck wrote:
Hi Martin,
I have seen this docs. But i don't understand the attachment hash...
Filename => "somefile.csv", Content => $ContentCSV, ContentType => "text/csv",
Which key is for the path of the file? Or which path is possible? ContentType is text/csv or image/png. What about pdf or else? What information contains $ContentCSV?
Thanks for your help
Marco
Martin Edenhofer schrieb:
Hi Marco,
On Apr 16, 2008, at 20:46 , Marco Rudzuck wrote:
I have a question about sending emails with attachment in OTRS 2.2.
Is it possible to send a pdf or word-document as attachment by calling $emailobject->send( Attachment => [{}] )?
Yes. :)
For more info see http://dev.otrs.org/ -> OTRS 2.2 -> Kernel::System::Email
Greetings,
-Martin
-- Mit freundlichen Grüßen Marco Rudzuck
TRUSTpact GmbH Schiefe Hardt 1 58093 Hagen M: 01733164921 F: 02371965327 E: marco.rudzuck@trustpact.com http://www.trustpact.com
_______________________________________________ OTRS mailing list: dev - Webpage: http://otrs.org/ Archive: http://lists.otrs.org/pipermail/dev To unsubscribe: http://lists.otrs.org/cgi-bin/listinfo/dev _______________________________________________ OTRS mailing list: dev - Webpage: http://otrs.org/ Archive: http://lists.otrs.org/pipermail/dev To unsubscribe: http://lists.otrs.org/cgi-bin/listinfo/dev
-- Mit freundlichen Grüßen Marco Rudzuck TRUSTpact GmbH Schiefe Hardt 1 58093 Hagen M: 01733164921 F: 02371965327 E: marco.rudzuck@trustpact.com http://www.trustpact.com