[ic] Email tag crash while sending two attachments

Mike Heins mike at perusion.com
Mon Nov 15 13:51:37 UTC 2010


Quoting Mike Heins (mike at perusion.com):
> Quoting Jan van Dijk (j.vandijk at attema.nl):
> > Dear all,
> >  
> > Adding a single attachment using the cgi tag works fine, adding multiple attachments using fixed filenames works fine also, 
> > but adding multiple attachments using the cgi tag results in a Runtime error: upload/[cgi ui_upload_filename1]: not readable.
> >  
> > [email 
> >     to=|foo at bar.com|
> >     subject=|Email with attachment|
> >     attach="upload/[cgi ui_upload_filename]"
> > ]This email has an attachment.(works fine)[/email]
> >  
> > [email
> >     to="foo <foo at bar.com>"
> >     subject="Email with attachments"
> >     attach.0="images/logo_infra.gif"
> >     attach.1="images/getacro.gif"
> > ]This email has two attachments.(works fine)[/email]
> >  
> > [email
> >     to="foo <foo at bar.com>"
> >     subject="Email with attachments"
> >     attach.0="upload/[cgi ui_upload_filename1]"
> >     attach.1="upload/[cgi ui_upload_filename2]"
> > ]This email has two attachments.(crashes)[/email]
> >  
> 
> As documented, you cannot include IC tags in hash members. This may have
> changed in 5.7, but was true before then.
> 
> Quick fix is:
> 
>     attach=` ["upload/$CGI->{ui_upload_filename1}","upload/$CGI->{ui_upload_filename2}"] `

And you can try with the previous code:

	[pragma interpolate_itl_references]

anywhere in the page.

-- 
Mike Heins
Perusion -- Expert Interchange Consulting    http://www.perusion.com/
phone +1.765.328.4479  <mike at perusion.com>

Opportunity is missed by most people because it is dressed in
overalls and looks like work. -- Thomas Edison



More information about the interchange-users mailing list