Entercom Communications Corp., one the nation’s largest broadcasters, will pay $4.25 million to end New York Attorney General Eliot Spitzer’s investigation of gifts — or “payola” — given by record companies in exchange for air play, Spitzer said Wednesday.

A lawsuit filed by Spitzer’s office in March claimed Entercom solicited payments from record labels and traded air time for promotional items, personal trips and other gifts.