Hi stephan here is some code that i have been working on works fine for me.
hope it helps !javascript:insertsmilie(';)')
Wink ;)
<%@LANGUAGE="JAVASCRIPT"%>
<%
// getting values from previous form
var sn,fn,surn,a1,a2,a3,ext,mobile,email,dob;
sn = Request.Form("staffNumber");
fn = Request.Form("firstname");
surn = Request.Form("surname");
a1 = Request.Form("address1");
a2 = Request.Form("address2");
a3 = Request.Form("address3");
ext = Request.Form("extn");
mobile = Request.Form("mobile");
email = Request.Form("email");
dob = Request.Form("day1") +"/"+Request.Form("month1")+"/"+Request.Form("year1");
adoConnection = Server.CreateObject("ADODB.Connection");
adoConnection.Open("DSN=input");
var SQL = "INSERT INTO tblStaff (staffID,firstname,surname,DateOfBirth,address1,ad dress2,address3,extn,mobile,email)";
SQL = SQL + "VALUES("+sn+",'"+fn+"','"+surn+"','"+dob+"','"+a1 +"','"+a2+"','"+a3+"',"+ext+","+mobile+",'"+email+ "')";
adoConnection.Execute(SQL);
adoConnection.Close();
adoConnection = null;
Response.Redirect("part1done.asp");
%>;););)
|