I learned about using rubber cement on rulers here on QB and consider it one of the best tips of the many I've learned. It's cheap, easy and effective and can be peeled off if it gets too much lint on it. I would worry that hot melt glue would create bumps that would be too big and might set the ruler atilt. Also, wouldn't it be hot enough at times to possibly damage the ruler?
I have more recently bought a couple of the Omni Grip rulers that are quite slip-proof without the rubber cement treatment, but everything else gets it.