JMail script der driller
Jeg er på Herrens mark... Jeg har nedenstående script som ikke kan udsende mit nyhedsbrev. Kan nogen her identificere om der er fejl i scriptet?Min webudbyder (Buydomains) giver mig denne fejl når jeg forsøger at sende:
jmail.SMTPMail error '8000ffff'
The message was undeliverable. All servers failed to receive the message
----Her er scriptet ----------
<%
Response.charset="iso-8859-1"
'Session.LCID=1030
DBSti = "DBQ=" & Server.Mappath("mindatabase.mdb")
Server.ScriptTimeout=6000
Response.buffer=true
if request("mode") = "send" then
Set DB = Server.CreateObject("ADODB.Connection")
DB.Open "DRIVER={Microsoft Access Driver (*.mdb)}; " & DBSti
if request.querystring("id") = "" then intcompanyID = 0
set RS = Server.CreateObject("adodb.Recordset")
SQL ="SELECT * FROM t_company WHERE (news_alm = 'on') ORDER BY companyID"
RS.Open SQL, DB, 3
TotalCount = RS.Recordcount
if TotalCount > 1 then Response.flush
Do While Not RS.EOF
if rs("e_mail") <> "" then
Set JMail = Server.CreateObject("JMail.SMTPMail")
JMail.ServerAddress = "smtpgateway.navneservice.com"
JMail.Sender = "minmail@minadresse.dk"
JMail.Priority = 3
JMail.Charset = "iso-8859-1"
JMail.ContentTransferEncoding = "8bit"
JMail.ContentType = "text/html"
JMail.Subject = request("header")
JMail.AddRecipient rs("e_mail")
JMail.Body = request("tekst")
JMail.Execute
%>
Sender Mail til : <%=rs("m_fornavn")%> - <%=rs("e_mail")%><br>
<%
' SQL2 = "UPDATE t_company SET newsmailsent = 1 WHERE companyID = " & rs("companyid") & ""
' DB.execute(SQL2)
end if
RS.MoveNext
Response.flush
Loop
DB.close
else
%>
<CENTER>
<TABLE BORDER="0">
<form action="nyhedsbrevsendes.asp" METHOD="POST">
<INPUT TYPE="hidden" NAME="mode" VALUE="send">
<TR>
<TD ALIGN="LEFT">
<FONT FACE="Arial" SIZE="2" COLOR="#000000"><STRONG>
Overskrift:
</STRONG></FONT>
</TD>
<TD ALIGN="LEFT">
<INPUT TYPE="TEXT" NAME="header" SIZE="50" value="Fast titel på mit nyhedsbrev">
</TD>
</TR>
<TR>
<TD ALIGN="RIGHT" VALIGN="TOP">
<FONT FACE="Arial" SIZE="2" COLOR="#000000"><STRONG>
Tekst:
</STRONG></FONT>
</TD>
<TD ALIGN="LEFT">
<TEXTAREA COLS="45" ROWS="15" NAME="tekst"></TEXTAREA>
</TD>
</TR>
<TR>
<TD ALIGN="LEFT">
</TD>
<TD ALIGN="RIGHT">
<input type="submit" value="-- SEND --">
</TD>
</TR>
</FORM>
</TABLE>
</CENTER>
<%
end if
%>