I just always bought a cleaner made for hardwood floors.
Just sweep the floors good and then mop the floors with the hardwood floor cleaner.
I've had to clean really old paint off of hardwood floors before where years ago, the painters sprayed this house and put NOTHING down to cover the hardwoods because they were going to lay carpet on top. The floors were covered in paint.
For that, I got Goof Off and scrubbed the paint off and then cleaned it with some hardwood cleaner. I then put some of the hardwood floor polish on top.
I'm sure they needed to be refinished but I wasn't ready to pay that kind of money. The floors looked ok after I did that though.