Implemented use_rails_ajax switch.