Enforce rules for popup windows