Fixed loop in AJAJ call

- TODO: address lookup
- TODO: fix setInterval call.