Hvorfor kommer dato i input felt i w3 jmail ikke med i mailen?
Jeg har lavet nedenstående kode og kan kun få dette felt:<br> Enter your question<br>
<textarea name="ContactText" cols="40" rows="15" wrap="PHYSICAL"></textarea>
..........med i jmailen. Hvad er der galt?
*********
Book2.inc
<form method="post" action="Booking12.asp?id=Book3" name="DateForm">
<p>Dag-måned-år*
<input type="text" name="DateField"> <br>Klik på <a href = "java script:popupInfokalender();">kalenderen!</a>
<applet
code=ccalendar.class
name=ccalendar MAYSCRIPT
archive = "ccalendar.jar"
width=200
height=200
id = "cal" >
<param name="fdw" value="1">
<param name="color_fond" value="c0c0c0">
<param name="color_full" value="FF0000">
<param name="color_case" value="c0c0c0">
<param name="color_Comment" value="C0C0C0">
<param name="color_empty" value="c0c0c0">
<param name="color_sd" value="ffffff">
<param name="strict" value="Vælg en anden dag!">
<param name="field" value="DateField">
<param name="form" value="DateForm">
<param name="day1" value="Søndag">
<param name="day2" value="Mandag">
<param name="day3" value="Tirsdag">
<param name="day4" value="Onsdag">
<param name="day5" value="Torsdag">
<param name="day6" value="Fredag">
<param name="day7" value="Lørdag">
<param name="month1" value="Januar">
<param name="month2" value="Februar">
<param name="month3" value="Marts">
<param name="month4" value="April">
<param name="month5" value="Maj">
<param name="month6" value="Juni">
<param name="month7" value="Juli">
<param name="month8" value="August">
<param name="month9" value="September">
<param name="month10" value="Oktober">
<param name="month11" value="November">
<param name="month12" value="December">
<param name="etarget" value="_new">
<param name="event_file" value="./rockrod#.evt">
<param name="sched_file" value="./rockrod#.txt">
<param name="field" value="DateField">
<param name="form" value="DateForm">
<param name="format" value="d-m-y">
</applet>
Ledig: <img src="../Images/Ledig.GIF" width="30" height="25,5" alt="" border="0">
Optaget: <img src="../Images/Optaget.GIF" width="30" height="25,5" alt="" border="0">
</p>
<input type="submit" value=" Submit ">
</form>
*************
Book3.inc
<form method="post" action="info.asp" name="DateForm">
<% name = server.HTMLEncode(request("DateField")) %>
<input type="hidden" name="DateField" value="<% = Dato%>">
<br> Enter your question<br>
<textarea name="ContactText" cols="40" rows="15" wrap="PHYSICAL"></textarea>
<br>
<input type="submit" value=" Submit ">
</form>
********
info.asp
<%@ language="vbscript" %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
<title>info.asp</title>
<link rel="stylesheet" type="text/css" href="stylesheets/stylesheet14.css">
<%
Session("strDato") = Request.Form("DateField")
Session("strText") = Request.Form("contactText")
%>
<%
Set JMail = Server.CreateObject("JMail.SMTPMail")
JMail.ServerAddress = "websmtp.rockrod.dk"
JMail.Sender = "info@rockrod.dk"
JMail.Subject = "Test af JMail, websmtp.rockrod.dk"
JMail.AddRecipient "info@rockrod.dk"
'JMail.AddAttachment "d:\home\ftpusername\www\test\ASP\ASPjmail\test.txt"
JMail.Priority = 3
JMail.AddHeader "Originating-IP", Request.ServerVariables("REMOTE_ADDR")
' ********** Her starter selve email-en
JMail.Body = "Dato: "
JMail.AppendText Session("strDato") & vbCrLf & vbCrLf
JMail.AppendText "Vedrørende: " & vbCrLf
JMail.AppendText Session("strText") & vbCrLf
' ********** Her slutter selve email-en
If Not JMail.Execute Then
Response.Write "ERROR MESSAGE: " & JMail.ErrorMessage & "<br/>" & vbCrLf
Response.Write "ERROR SOURCE: " & JMail.ErrorSource & "<br/>" & vbCrLf
Response.Write "LOG: <pre>" & JMail.Log & "</pre>" & vbCrLf
Else
Response.Write "<html><body>Emailen er sendt!</body></html>"
End If
Set JMail = Nothing
%>
<body>
<!--#include file="include/menu14.inc"-->
<h6><div id="indhold">
Emailen er sendt!
</div></h6>
<!--#include file="include/fodnote.inc"-->
</body></html>