
13-11-2007, 07:38
|
|
|
|
חבר מתאריך: 23.10.07
הודעות: 12
|
|
בעיה בקוד
שלום אני מנסה ליצור דף להדלקת נר זיכרון אבל לא מכניס לי את הפרטים שמילו בטופס לתוך דטה בייס בבקשה עזרה זה מאוד חשוב
הקוד נראה ככה בבקשה לתקן
<%
Response.Buffer = true
Dim DB_CONNECTIONSTRING
DB_CONNECTIONSTRING = "Provider=Microsoft.Jet.OLEDB.4.0;" _
& "Data Source=" & Server.Mappath("commemoration.mdb") & ";"
Dim I
Dim strSQL
Dim iRecordAdded
Dim objRecordset
Set objRecordset = Server.CreateObject("ADODB.Recordset")
strSQL = "SELECT * FROM candle"
objRecordset.Open strSQL, DB_CONNECTIONSTRING, 1, 2, &H0001
objRecordset.AddNew
dim errorMessage
errorMessage=" <center><font color=red size=6>"&"<b>"
if Request.Form("text1")= "" then
errorMessage=errorMessage & "שם בבקשה"
elseif Request.Form("textarea1")=" " then
errorMessage=errorMessage & "כמה מילים בבקשה"
else
objRecordset.Fields("name")= Request.Form("text1")
objRecordset.Fields("detail")= Request.Form("textarea1")
objRecordset.Update
objRecordset.Close
Set objRecordset = Nothing
Response.Redirect "candle2.asp"
end if
errorMessage=errorMessage & "</font>"
%>
<%=errorMessage%>
</center>
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=windows-1255">
<META http-equiv=Content-Type content="text/html; charset=iso-8859-8">
<META http-equiv=Content-Type content="text/html; charset=visual">
<title>הדלקת נר זיכרון</title>
<body bgcolor="#000000">
<center>
<DIV ID="idElement1" style="LEFT: 0px; WIDTH: 721px; POSITION: absolute; TOP: 0px; HEIGHT: 111px">
<OBJECT id=ShockwaveFlash1
codebase="http://download.macromedia.com/pub/...version=5,0,0,0"
height=110 width=720 align=right
classid=clsid 27CDB6E-AE6D-11cf-96B8-444553540000><PARAM NAME="_cx" VALUE="19050"><PARAM NAME="_cy" VALUE="2910"><PARAM NAME="FlashVars" VALUE="19050"><PARAM NAME="Movie" VALUE="logo.swf"><PARAM NAME="Src" VALUE="logo.swf"><PARAM NAME="WMode" VALUE="Window"><PARAM NAME="Play" VALUE="-1"><PARAM NAME="Loop" VALUE="-1"><PARAM NAME="Quality" VALUE="High"><PARAM NAME="SAlign" VALUE=""><PARAM NAME="Menu" VALUE="-1"><PARAM NAME="Base" VALUE=""><PARAM NAME="AllowScriptAccess" VALUE="always"><PARAM NAME="Scale" VALUE="ShowAll"><PARAM NAME="DeviceFont" VALUE="0"><PARAM NAME="EmbedMovie" VALUE="0"><PARAM NAME="BGColor" VALUE=""><PARAM NAME="SWRemote" VALUE="">
<embed src="logo.swf" quality=high pluginspage="http://www.macromedia.com/shockwave...=ShockwaveFlash" type="application/x-shockwave-flash" width="720" height="110">
</embed></OBJECT>
</DIV></center>
<p> </p>
<form method=post action="candle2.asp" id=form1 name=form1>
<BODY bgColor=black>
<P align=center> </P>
<P align=center><u><font size="6" color="#FFFFFF"><b><i>נר זיכרון</i></b></font></u></P>
<P align=center> </P>
<P align=center>
<INPUT id=text1 name=text1 size="20" ><FONT
color=white>
: </FONT><FONT color=white>שם</FONT><FONT color=white> <br></FONT></P>
<P align=center><FONT color=#ffffff>
: כמה מילים <br></FONT><TEXTAREA id=textarea1 name=textarea1 rows=5 cols=30>
</TEXTAREA><br></P>
<P align=center>
<FONT color=white>
<BR></FONT>
<INPUT id=submit1 type=submit value=הדלק name=submit1 style="WIDTH: 78px; HEIGHT: 24px" size=43></P></FORM></BODY></HTML>
|