I carry a hot glue gun just for the purpose of mounting transformers on the floor. It also provides mechanical protection by providing some "give" if a fork lift hits it.

I'm not advocating leaning panels against the wall, but I've seen a few transformers hung by threaded rod from the ceiling and they move quite freely. Sitting on the floor is way more secure - without glue.

The other electrician, in the original post, has a good point. Are there any rules about mounting transformers? What is secure?