For a five hour layover, I don't think you'll need a hotel. After all, you've got plenty of time to sleep on the plane, both coming and going! There's nothing else like the Dubai Airport. It is a huge shopping mall with lots of restaurants and shops to explore. My advice would be to sample some local Middle Eastern cuisine.
When I was there in January, 2010, the security inside the airport was pretty tight. We were free to roam around the terminal to visit the shops and restaurants, but the lounges at each departure gate were walled off. To get in there, they didn't just screen our carry-on bags and purses, but actually rummaged through them all. Just giving you a heads up.