Cut the edges off one commercial rubber furniture grip using sharp scissors. Trim enough off so that the rubber grip is only about a quarter-inch wider than the legs of the bed. Don't trim castor cups because they are made of formed plastic with no-skid rubber bottoms.
Move the bed to exactly where you want it to be. Lift it rather than push it so you don't mar the surface of your hardwood floor. Recruit a helper if you need to.
Lift one leg of the bed up slightly and place a shaped rubber furniture grip directly under it. For a wheeled bed, slide a castor cup underneath.
Lower the bed leg down so the end is exactly in the center of the grip. Press the leg down firmly into the soft rubber. Repeat with the other legs. Ensure any wheeled legs are centered in the castor cup.
Press down firmly on the bed over each leg one more time to affix the rubber furniture grips to the floor. Test the bed by pushing against one edge to ensure it no longer slides across the floor. Add a second trimmed rubber furniture grip under the first one if there is still some slippage. Repeat with each leg.