Chapter 4: Lavaridge Gym
Exit the Mauville Gym and head north to find Team Aqua. Go north again to find Route 111. Follow it north until you find the small rocks. Use Rock Smash to break them and continue north. Head west at the sig to find Route 112 and Brendan/May. He will give you HM04 Strength. Continue west and head up the stairs to the north. Enter the cave - Fiery Path - and travel north through it.
Exit the cave back on Route 112. Continue traveling and head north to find Route 111. Continue down it to meet with Aarune. He gives you TM94 Secret Power and Decoration. Exit the Secret Base and continue along Route 111 going north. You will come to Route 113 eventually. Continue down it to find Brendan/May once more. Now continue following Route 113 until reaching Fallarbor Town.
Brendan/May will appear and after a short dialog - exit the building. Head west to find Route 114. Follow the path and go across the bridge to the south. Continue following Route 114 until you reach Brendan/May. He will run off after a moment. Follow him and continue following the trail. You will find a cave shortly - Meteor Falls. Enter it and you will find Brendan/May and others to the west.
Battle with Aqua Member Shelly and Team Aqua Grunt. Defeat them for a dialog. Afterwards - the Professor gives you the TM23 Smack Down. Travel with Brendan/May back to Mauville. Head north to Route 111 and continue until Route 112. Now enter the building atop the stairs and ride the Cable Car to Mt. Chimney. Head north to find Team Magma and Team Aqua. A short dialog will ensue.
Continue following the trail and battle with the Team Aqua Grunt. Continue north and you will find Aqua Admin Shelly. Battle her and continue across to find Aqua Leader Archie. After the battle - head back south and continue until you reach the Jagged Pass. Continue south down Jagged Pass until you reach Route 112. Now head west to find Lavaridge Town.
Head to the Lavaridge Gym. Now drop down the first trap door. Go up the right most water spout. Drop down the northern most trap door. Head up the left most water spout. Go down the northern most trap door. Head up the right most water spout. Head down the southern trap door. Head up the left water spout and get ready to battle the Lavaridge Gym Leader.
Gym #4 Lavaridge Gym - Leader Flannery
Lavaridge Gym Leader Flannery specializes in Fire-type Pokémon. You'll need to navigate the two floors of Lavaridge Gym to make it up to the leader. A strong Water-type should make easy work of Flannery's Pokémon. Flannery also has a weakness to Rock-type, if Water isn't an option for you. Pelipper is a good choice that also has the ability to learn many HMs and an evolved Geodude could probably do the trick. Watch out for the hard-hitting Overheat and be ready for her to use Super Potions.
Flannery will reward you with the Heat Badge and TM50 - Overheat for defeating her. The Heat Badge will make it so all Pokémon Level 50 and below will obey you and will allow you to use the HM Strength outside of battle.