Some ajax stuff, final part 2 done