我读过关于Email::Stuff的文章,并在网上看到了一些例子。因此,所有的示例都没有创建对象。它们就像这样消失了:
Email::Stuff->to('Simon Cozens<simon@somewhere.jp>')
->from('Santa@northpole.org')
->text_body("You've been a good boy this year. No coal for you.")
->attach_file('choochoo.gif')
->send;当我按照上面的方法操作时,我得到了错误Can't locate object method "to" via package "Email::Stuff" (perhaps you forgot to load "Email::Stuff"?) at ./test.pl line 27.。谁能举例说明如何使用Email::Stuff?
发布于 2010-07-17 15:40:43
与所有Perl模块一样,您必须对它们执行use操作。
use Email::Stuff;https://stackoverflow.com/questions/3270505
复制相似问题