Bookmarks

Yahoo Gmail Google Facebook Delicious Twitter Reddit Stumpleupon Myspace Digg

Search queries

procmail modify subject, procmail alter subject, formail get body of message, www.xxxcon, www xxxcon, board.issociate.de, registrieren fehler dll server 0x8002801c, far2 vs near2 raid10, access abfragen aus linux, "Can't send mail: sendmail process failed with error code 69"

Links

XODOX
Impressum

#1: include file within script

Posted on 2008-04-17 00:10:40 by Shank

I have the below code to auto-email a customer.

What is the syntax to include a file in the email? <!--#include
file="agreement_inc.asp" -->

HTML = HTML & "...just some text...<br>"
HTML = HTML & <!--#include file="agreement_inc.asp" -->
HTML = HTML & "</body>"
HTML = HTML & "</html>"

thanks

Report this message

#2: Re: include file within script

Posted on 2008-04-17 03:05:03 by Bob Milutinovic

"shank" <shank@tampabay.rr.com> wrote in message
news:eRLZ95AoIHA.4292@TK2MSFTNGP04.phx.gbl...
>I have the below code to auto-email a customer.
>
> What is the syntax to include a file in the email? <!--#include
> file="agreement_inc.asp" -->
>
> HTML = HTML & "...just some text...<br>"
> HTML = HTML & <!--#include file="agreement_inc.asp" -->
> HTML = HTML & "</body>"
> HTML = HTML & "</html>"
>
> thanks
>

sIncludeFile = "somefile.txt" ' modify as appropriate
set oFSO = Server.CreateObject("Scripting.FileSystemObject")
set fRead = oFSO.OpenTextFile(sIncludeFile)
sReadText = fRead.ReadAll
fRead.Close
set fRead = nothing
set oFSO = nothing

HTML = HTML & "...just some text...<br>"
HTML = HTML & sReadText
HTML = HTML & "</body>"
HTML = HTML & "</html>"



HTH,

- Bob.

Report this message