Abstract closest_parent into the viewhelper class.