Hallo Paul, On Sun, 4 Jan 2009 18:30:17 +0000GMT (4-1-2009, 19:30 +0100, where I live), you wrote:
PM> From: %OFromName <%OFromAddr>
PM> Sent%-
PM> %VARdate='%SetPattRegExp="^Date:.*?$"%RegExpMatch=%HEADERS'%-
PM> %SetPattRegExp=":.*$"%RegExpMatch="%VARdate"
PM> %SetPattRegExp="^To:.*?$"%IF:"%RegExpMatch=%HEADERS"<>"":"To: %OToList
PM> ":""%-
PM> %SetPattRegExp="^Cc:.*?$"%IF:"%RegExpMatch=%HEADERS"<>"":"Cc: %OCcList
PM> ":""%-
PM> Subject: %OSubj
The value after %RegExpMatch= should be between quotation marks, like
you've done in %RegExpMatch="%VARdate" But in the other instances
You're using %RegExpMatch=%Headers without quotation marks, it's
possible that HTML templates are somewhat stricter where the syntax is
concerned.
Furthermore I'm somewhat lost about your extensive use of regular
expressions where they aren't necessary.
You're using regexp to retrieve the original contents of the Date
header, where %OHeader('Date') would suffice.
You're using some regexp to check whether %OToList is empty and if it
isn't you're inserting %OToList, why not simply use %OToList to
check whether it's empty instead of the regexp, same with %OCcList.
I'd propose something like this:
From: %OFromName <%OFromAddr>
Sent: %OHeader('Date')
%If:"%OToList"<>"":"To: %OToList
":""%-
%If:"%OCcList"<>"":"Cc: %OCcList
":""%-
Subject: %OSubject
No, I didn't check this.
--
Groetjes, Roelof
Windows: Ultimate memory manager. It manages to use it all.
http://www.voormijalleen.nl/
The Bat! 4.1.7.1
Windows Vista 6.0 Build 6001 Service Pack 1
3 pop3 accounts
OTFE enabled
Quad Core 2.4GHz
4 GB RAM
pgpJ4P74qrPLl.pgp
Description: PGP signature
________________________________________________ Current version is 4.1.7 | 'Using TBUDL' information: http://www.silverstones.com/thebat/TBUDLInfo.html

