Simple Ajax request encapsulation