edited version of cpancake's cash4ads