السلام عليكم
اريد ان ارسل متغيريين بالدالة send
لم انجح
يعمل بشكل جيد بهده الطريقة
{
var txtname = document.getElementById("txtname");
mail = document.getElementById("mail");
xmlhttp.open("POST","adduser.php",true); //calling testing.php using POST method
xmlhttp.onreadystatechange = handleServerResponse;
xmlhttp.setRequestHeader('Content-Type', 'application/x-www-form-urlencoded');
xmlhttp.send("txtname=" + txtname.value);
}لكن بهده لا يعمل
{
var txtname = document.getElementById("txtname");
mail = document.getElementById("mail");
xmlhttp.open("POST","adduser.php",true); //calling testing.php using POST method
xmlhttp.onreadystatechange = handleServerResponse;
xmlhttp.setRequestHeader('Content-Type', 'application/x-www-form-urlencoded');
xmlhttp.send("txtname=" + escape(txtname) + "&mail=" + escape(mail));
}الكلمة التي اجدها في قاعدة البيانات عوض الاسم و الايميل الدي يفترض ارساله الى قاعدة البيانات
اجد
[object HTMLInputElement]