fixes for ajax
ajax fixes