Defeating the Flame Dancer
Proceed through the Fire Temple until you reach the first miniboss -- a fight with a dancer made entirely of flame, save for a spherical black core. Use your Hookshot to pull the core out of the flames, then attack it before it can jump back. Do this as many times as necessary until you've defeated the dancer, then jump on the platform it occupied -- it rises through a passage in the ceiling.
Reaching the Megaton Room
When you jump on the platform the dancer occupied, it rises into the ceiling. When it stops, proceed down the hall and climb the first wall you come to in the next room, then drop a bomb off the right edge to trigger the Crystal Switch. Climb the next wall and go through the door at the top.
Extinguishing the Flames
Climb the ledge in front of you and hit the switch. On the other side of the large room you've just entered, the protective flames around the treasure chest disappear, but only temporarily, so you have to reach the chest quickly.
Opening the Chest
Drop down from the ledge and run along the long curving flight of stairs as quickly as you can without falling. Press "A" to move faster by rolling forward. If you reach the chest before the flames reappear, open it immediately to obtain the Megaton Hammer.