Also, for the filter floss, you can even rinse it out under the sink. I rinse mine out til it starts getting bad, then I replace it. For the filter media, I never replace, just occasionally rinse it in tank water if it's starting to get all yukky looking, to get all the gunk out. But don't over-rinse it, or use tap water.
As for the foam, rinse it in tank water. When it starts falling apart, then replace. Will probably take 10 years or more before it starts falling apart, lol.