In the messed up app, hold the lock button until it says slide to power off. Then hold the home button for about 7 seconds. It will force quit the app. If that doesn't fix it, power cycle your iThingie.
See, I knew about that, but usually that locks the phone in portiait, not landscape.
To remove:
Double tap the home button and the multi-tasking menu will appear. Swipe left (move your finger right) over the menu and a music player/ orientation lock will show up.
lol..double tap the home button...scroll one time to the left, and click the left icon...it should have a lock on it...make sure it has no lock on it thats how you know its unlocked