added some buggy ajax to the index page