Hey guys,
Thanks for reading this, I am lost once again.
I am having trouble understanding how the string is sent in the post method from ajax and how to feed it in to php correctly. I am able to get all my scripts to work but it apears that an incorrect id value is being passed to the server.
Here is the snippet where i am having trouble.
function ajaxFunction() {
var getdate = new Date();
var fpassword = document.getElementById('fpassword').value;
var fusername = document.getElementById('fusername').value;
var queryString = "fpassword=" + fpassword + "fusername=" + fusername;
if(xmlhttp) {
var txtname = document.getElementById("txtname");
xmlhttp.open("POST","checklogin.php",true); xmlhttp.onreadystatechange = handleServerResponse;
xmlhttp.setRequestHeader('Content-Type', 'application/x- xmlhttp.send(queryString);}}
I think I am doing something wrong when I putt the querystring together.
This is apart of a login script and all the code work however no matter what username and password that are entered access is denied.
Thanks for reading this, I am lost once again.
I am having trouble understanding how the string is sent in the post method from ajax and how to feed it in to php correctly. I am able to get all my scripts to work but it apears that an incorrect id value is being passed to the server.
Here is the snippet where i am having trouble.
function ajaxFunction() {
var getdate = new Date();
var fpassword = document.getElementById('fpassword').value;
var fusername = document.getElementById('fusername').value;
var queryString = "fpassword=" + fpassword + "fusername=" + fusername;
if(xmlhttp) {
var txtname = document.getElementById("txtname");
xmlhttp.open("POST","checklogin.php",true); xmlhttp.onreadystatechange = handleServerResponse;
xmlhttp.setRequestHeader('Content-Type', 'application/x- xmlhttp.send(queryString);}}
I think I am doing something wrong when I putt the querystring together.
This is apart of a login script and all the code work however no matter what username and password that are entered access is denied.