Added :before and :after callback functionality