They deck it with silver and with gold
Cover it with plates of silver and gold, for the sake of ornament, that it may look grand, majestic, and venerable; and by this means draw the eye and attention, and so the devotion of people to it: they fasten it with nails and hammers, that it move not.
The sense is, either that the idol was fastened to some post or pillar, or in some certain place on a pedestal, that it might not fall, it not being able otherwise to support itself; or the plates of silver and gold, as Kimchi thinks, were fastened to the idol with nails and hammers, that so they might not be taken away from it; for, were it not for the nails, the god would not be able to keep his silver and golden deckings.