View Single Post
05-23-2007, 11:24 PM
#2
Salathe is offline Salathe
Salathe's Avatar
Status: Community Archaeologist
Join date: Jul 2004
Location: Scotland
Expertise: Software Development
Software: vim, PHP
 
Posts: 3,820
iTrader: 25 / 100%
 

Salathe will become famous soon enough

Send a message via MSN to Salathe

  Old

You don't want to be sending anything within the send() call since this is a GET request. That would be alright if you were POSTing the data, but for a GET you just append the data to the URL ("time.php?name=...").

Code:
var url = "time.php?name=" 
        + document.myForm.username.value 
        + "&password=" 
        + document.myForm.password.value;
xmlHttp.open("GET", url, true);
xmlHttp.send(null);