def convert_to_ajax(page, context_instance):
 response = apply_rules(page)
 return response

def convert_to_ajax ( page , context_instance ) : response = apply_rules ( page ) return response
converts django html response into ajax response represented by a dict() .