changed close method to use jQuery remove