moved ajax calls into the $(document).ready()