You're likely looking for the
LastFM Firefox Extension
.