How to get the Squeaks out of floors?

I have an older home and the hardwood floors have loosened over the years. I'm planning to strip and refinish to bring them back to life. While doing that, what's the best way to re-fasten the boards down and get rid of the squeaks and creaks.?
  3 answers