Re: [Zope] Re: File Attachments with Sendmail

2000-09-04 Thread Brendon Grunewald

Dear Luis,

Dieter Mauer was kind enough to assist me with the answer to this question.
The normal Sendmail tag does not accept variables.

You need to install the MIME.py.patch. Once that is done you can include
variables.

Brendon

- Original Message -
From: "Luis Cortes" [EMAIL PROTECTED]
To: "Brendon Grunewald" [EMAIL PROTECTED]
Cc: "Zope mailing list" [EMAIL PROTECTED]
Sent: Monday, 04 September, 2000 10:03
Subject: Re: [Zope] Re: File Attachments with Sendmail


 Great answer, but I have one question:

 dtml-boundary name="dtml-var Required_Doc" type=application/octet-stream
 disposition=attachment encode=base64

 does not expand the Required_Doc name, do anyone know why??




 - Original Message -
 From: "Brendon Grunewald" [EMAIL PROTECTED]
 To: "Chris Withers" [EMAIL PROTECTED]
 Cc: [EMAIL PROTECTED]
 Sent: Thursday, August 31, 2000 5:12 AM
 Subject: [Zope] Re: File Attachments with Sendmail


  Hi Chris,
 
  This is what I have in total. I know I am being stupid, but this is
  frustrating me to hell. Perhaps I should not be doing this at 1AM.
 
  The form looks like this:
  
  dtml-var standard_html_header
  form METHOD="POST" ACTION="send_webdoc"
  Please provide the following information: br
  br
  Email address:
  input TYPE="TEXT" NAME="Email_address" SIZE="20"
  br
  Document:
  SELECT NAME="Required_Doc"
  OPTIONBrochure.doc/OPTION
  OPTIONPricelist.xls/OPTION
  OPTIONMap.pdf/OPTION
  /SELECT
  br
  pinput TYPE="submit" VALUE="Send Form" input TYPE="RESET"
 VALUE="Reset
  Form" /p
  /form
  dtml-var standard_html_footer
  -
 
  send_webdoc looks like this...
  ---
  html
  head
  TITLE!--#var title_or_id--/TITLE
  meta http-equiv="Refresh" content="5; url=!--#var Redirect_URL--"
  /head
  BODY !--#var BackgroundImage --
 
  dtml-sendmail mailhost="MailHost"
  To: dtml-var Email_address
  From: WebForm [EMAIL PROTECTED]
  Subject: Web Doc Request
  dtml-mime type=text/plain encode=7bit
  Attached is the document you requested: dtml-var Required_Doc
  dtml-boundary name="dtml-var Required_Doc"
type=application/octet-stream
  disposition=attachment encode=base64
  dtml-var "Required_Doc.read()"
  /dtml-mime
  /dtml-sendmail
 
  H2Form Information Confirmation/H2
  Thank you the document should be email to you immediately.BR
  You should be automatically redirected in a few seconds.BR
  p
  If not
  a href="!--#var Redirect_URL--"Click here/a.
  /p
  dtml-var standard_html_footer
  --
 
  Thanks
  Brendon
 
  --
  70South: the No.1 source for Antarcticles.
  For the latest news and views on Antarctica visit :
http://www.70south.com
 
 
  ___
  Zope maillist  -  [EMAIL PROTECTED]
  http://lists.zope.org/mailman/listinfo/zope
  **   No cross posts or HTML encoding!  **
  (Related lists -
   http://lists.zope.org/mailman/listinfo/zope-announce
   http://lists.zope.org/mailman/listinfo/zope-dev )
 




___
Zope maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope-dev )




[Zope] Re: File Attachments with Sendmail

2000-08-31 Thread Chris Withers

Brendon Grunewald wrote:
 The form looks like this:
snip form

That looks okay...

 meta http-equiv="Refresh" content="5; url=!--#var Redirect_URL--"

could you just use:
dtml-call "RESPONSE.redirect(Redirect_URL)"
somewhere on the page instead of the meta-refresh nastiness?

 Attached is the document you requested: dtml-var Required_Doc

I do hope Required_Doc is a string or a function returning a strign and
not the actual document ;-)

 dtml-boundary name="dtml-var Required_Doc" type=application/octet-stream
   ^^^
   Oops, DTML-inside-DTML error ;-)

...and a major falling down of the sendmail tag, this should be
expressionable, I don't know if there is somethign to solve this yet...

 disposition=attachment encode=base64

 dtml-var "Required_Doc.read()"
 /dtml-mime

what is Required_Doc?

cheers,

Chris

___
Zope maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope-dev )




[Zope] Re: File Attachments with Sendmail

2000-08-31 Thread Brendon Grunewald


Required_Doc is the variable set in the form. (see my previous email for
details onthe form).

Basically I want the following functionality:
1. Enter email address:
2. Select document of file to be emailed.
3. Click Send and Bang, off it goes!

Brendon


- Original Message -
From: "Chris Withers" [EMAIL PROTECTED]
To: "Brendon Grunewald" [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Sent: Thursday, 31 August, 2000 14:22
Subject: Re: File Attachments with Sendmail


 Brendon Grunewald wrote:
  The form looks like this:
 snip form

 That looks okay...

  meta http-equiv="Refresh" content="5; url=!--#var Redirect_URL--"

 could you just use:
 dtml-call "RESPONSE.redirect(Redirect_URL)"
 somewhere on the page instead of the meta-refresh nastiness?

  Attached is the document you requested: dtml-var Required_Doc

 I do hope Required_Doc is a string or a function returning a strign and
 not the actual document ;-)

  dtml-boundary name="dtml-var Required_Doc"
type=application/octet-stream
^^^
Oops, DTML-inside-DTML error ;-)

 ...and a major falling down of the sendmail tag, this should be
 expressionable, I don't know if there is somethign to solve this yet...

  disposition=attachment encode=base64

  dtml-var "Required_Doc.read()"
  /dtml-mime

 what is Required_Doc?

 cheers,

 Chris



___
Zope maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope-dev )