PDA

View Full Version : AJAX: Posting Variables?



benjaminj88
25 Sep 2010, 02:28 AM
Alright so after realizing my code works I realized more or less my problem but have yet to come to a solution. So now what I want is basically will essentially be some links which depending on the posted data will change, the only thing is that I want these links placed on the same page that will be recalled, any ideas?
my java: (ALOT REMOVED)
move(x,y){
...
xmlhttp.send("xPosition="+x+"&yPosition="+y);
}

my onclick event:
<a onclick="move(x,y)">Move</a>

The page should display a map with some tiles having the onclick function. When clicked the page will reload in the designated div, with the new x and y position, any ideas as to how to do this?