db updates, formatting changes, fix ajax bug