psychopath wrote:
Is this available? |
OK Ive installed it at http://webwiz.infobahn.co.nz to see how involved
it was for a 7.7a fresh install and it went in flawlesly.
Couple of catches
- At the moment it only uses JMail, but the Windows Script can easily be written for various components.
- The Windows Script resides on the WWW Server (ie created a new
Scripts folder in the WWF install) and is run by Microsoft Schedular
every 5 mins. Thus you need acecss to the server, or atleast your
ISP to setup the schedule.
- The Script checks a remote POP3 box which has a wildcard for a
"domain". In this case its easier to setup a subdomain (eg
forum.domain.com) with an MX record allowing all mail to be collected
in the POP3 box.
- The VBScript above collects all the Emails from the POP3 box and
places them in a new table called emailmessages. It also collects
any attachments and saves them to the forum hard drive (renaming them
to avoind and duplicate issues)
- All messages in the above table are then processed by a Stored
Procedure (the step above also uses a stored procedure). This
proc checks for messages of a certain status (ie not yet imported to
forum), checks the users posting privs (based on Email address) , and
then either adds a new topic or adds a new reply to an existing
topic. Thus it is possible to actually start a new thread via
Email. If a message fails any of the security checks, it is
deleted and not posted.
- Once a message is added to the fourm, the processing Proc above
then sends out the notifications in exactly the same manner as the
Forum ASP does (and does the same checks, eg not sending to the current
user). This allows total interaction via Email, ie reply to a
post, and also have the Email post sent out to everyone else.
THis latter step uses a third table called "mailtable", which basically
holds Emails being sent from the forum stored procedures and these are
sent by a SQL job.
- The only change to WWF code is in the following WWF pages
forum_posts.asp
if isNull(strAuthorIP) then 'CJH Added EMail Icon
response.write(VbCrLf &
" <img
src='forum_images/e-mail_sent.gif' alt='sent via Email' width='18'
height='17' border='0'>")
end if
|
This will show a little Email Icon for posts delivered by Email
post_message.asp
strEmailMessage = strEmailMessage
& "<p>" & strTxtEmailEmailToReply & "<br
/>"
|
So that there is a comment in the delivered Emails about clicking reply
(this therefore needs the CONST set in your language file)
and
'Call the function to send the e-mail
blnEmailSent = SendMail(strEmailMessage,
decodeString(strUserName),
decod eString(strUserEmail), strMainForumName,
decodeString(intForumID & "." & lngTopicID &
"@forum.domain.com"), strEmailSubject, strMailComponent, true)
|
All in all it seems to work really well. The attachments are
successfully added to the forum posting, as tho' they wer done via the
WWW interface. It also obeys formatting comments, in that if the
Email posting is in HTML, then it posts (Email and WWW) via HTML.
If in plain text, then the Email that gets sent out is also plain
text. Saves seeing HTL code headers.