huangkuan,
If you poke around a little on the discussion forum, you will see that
this topic has been covered. To recap:
1) Create a Thread that runs at some interval to check for the latest
position ...
// runs every 10 secs
Thread t = new Thread("checkAndSendLocation()", 10000);
http://where.com/create/reference/variables.php#thread
2) In checkAndSendLocation(), pull the latest position ...
var lat = load('pos_lat');
var lng = load('pos_lng');
(this unfortunately is not well documented on site)
3) In checkAndSendLocation(), perform fetch() on a <form>
<script>
function checkAndSendLocation() {
var lat = load('pos_lat');
var lng = load('pos_lng');
document.sendPosForm.lat.value = lat;
document.sendPosForm.lng.value = lng;
document.sendPosForm.fetch()
}
</script>
// down here include necessary <form> with id = "sendPosForm"
http://where.com/create/reference/variables.php#form
Hope that helps,