Body
Mit spørgsmål er nok meget simpelt, men nu har jeg tonsed med det i 4 timer. sååå hjælp.Som det kan ses på nedenstående ønsker jeg at returnere en mail ved en form det er der ingen problemmer i men i mailen ønsker jeg en masse tekst jeg har prøvet objMail.Body = men kan kun have begrænsede tekst så hvordan skal jeg skrive det...
<% @LANGUAGE = VBScript %>
<% Option Explicit %>
<html>
<head>
<title>test</title>
<title>test</title>
</head>
<body bgcolor=#ffffff>
<%
Dim strName, strEmail, strAdress, strQuery, strBy
strName = Trim(Request.Form(\"ClientName\"))
strEmail = Trim(Request.Form(\"ClientEmail\"))
strAdress = Trim(Request.Form(\"ClientAdress\"))
strQuery = Trim(Request.Form(\"ClientQry\"))
strBy = Trim(Request.Form(\"ClientBy\"))
If (strName <> \"\" And strAdress <> \"\" And strBy <> \"\") Then
Dim objMail, aRecipients
Set objMail = Server.CreateObject(\"CDONTS.NewMail\")
objMail.From = \"22@xx.dk\"
objMail.To = strEmail
objMail.Subject = \"Fremsendelse af opstilling via eMail til \" & strName
aRecipients = Array(\"11@xx.dk\", _
\"33@xx.dk\")
objMail.AttachFile Server.MapPath(\"../Pdfer/1809_d6.PDF\")
objMail.BCC = Join(aRecipients, \";\")
objMail.Body = \"Hermed fremsendes den bestilte opstilling! \" & strName
objMail.Send
Response.Write \"Tak for din bestilling! \" & strName
Set objMail = Nothing
Else
%>
<h1> </h1>
<p> </p>
<FORM ACTION=\"<%=Request.ServerVariables(\"SCRIPT_NAME\")%>\" METHOD=POST>
<TABLE BORDER=0>
<tr><td>Name:</td><td><IMG border=0 src=\"../images/stjerne.gif\" width=\"10\" height=\"10\"></td><td><INPUT NAME=\"ClientName\" VALUE=\"\" SIZE=57></td></tr>
<tr><td>Adresse:</td><td><IMG border=0 src=\"../images/stjerne.gif\"></td><td><!--webbot
bot=\"Validation\" S-Validation-Constraint=\"Greater than\"
S-Validation-Value=\"1\" --><input type=\"text\" name=\"ClientAdress\" size=\"57\"></td></tr>
<tr><td>Postnr. og by:</td><td><IMG border=0 src=\"../images/stjerne.gif\" width=\"10\" height=\"10\"></td><td><!--webbot
bot=\"Validation\" S-Validation-Constraint=\"Greater than\"
S-Validation-Value=\"1\" --><input type=\"text\" name=\"ClientBy\" size=\"57\"></td></tr>
<tr><td>Tlf:</td><td></td><td><input type=\"text\" name=\"telefon\" size=\"18\">Tlf (arbejde/mobil):<input type=\"text\" name=\"TlfArbejde\" size=\"16\"></td></tr>
<tr><td>eMail:</td><td></td><td><INPUT TYPE=TEXT NAME=\"ClientEmail\" VALUE=\"\" SIZE=40></td></tr>
<tr><td valign=top>Comment/Question</td><td></td><td><TEXTAREA NAME=\"ClientQry\" COLS=40 ROWS=10></TEXTAREA></td></tr>
<tr><td></td><td></td><td>
<p><INPUT TYPE=SUBMIT VALUE=\"Send\"></p>
</td></tr>
</TABLE>
</FORM>
<% End If %>
<p> </p>
</body></html>
Jeg har læst ASP af Christoph og de har en kode der ser sådan her ud
<% @LANGUAGE = VBScript %>
<%
Option Explicit
Dim objMail, htmlText
Set objMail = Server.CreateObject(\"CDONTS.NewMail\")
htmlText = \"<!DOCTYPE HTML PUBLIC \"\"-//W3C//DTD HTML 4.0 Transitional//EN\"\">\"
htmlText = htmlText & \"<html>\"
htmlText = htmlText & \"<head>\"
htmlText = htmlText & \"<title>ASP24h.com Site Launched!</title>\"
htmlText = htmlText & \"</head>\"
htmlText = htmlText & \"<body bgcolor=#ffffff>\"
htmlText = htmlText & \"<center>\"
htmlText = htmlText & \"<p>A companion site for the \"\"Teach \"
htmlText = htmlText & \"Yourself ASP in 24 Hours\"\" book has been launched at <a href=\"\"http://www.asp24h.com\"\">\"
htmlText = htmlText & \"http://www.asp24h.com</a>.</p>\"
htmlText = htmlText & \"<img src=\"\"softwing.gif\"\">\"
htmlText = htmlText & \"</center>\"
htmlText = htmlText & \"</body>\"
htmlText = htmlText & \"</html>\"
objMail.From = \"webmaster@asp24h.com\"
objMail.To = \"christophw@softwing.com\"
objMail.Subject = \"New ASP Book Site\"
objMail.BodyFormat = 0
objMail.MailFormat = 0
objMail.Body = htmlText
objMail.AttachUrl Server.MapPath(\"softwing.gif\"), \"softwing.gif\"
objMail.Send
Set objMail = Nothing
%>
Men hvordan kombinere jeg de 2 sider
steens