Basically, do whatever the heck it takes to get them moving forward. I don't care if it is beating on their ass. Rearing is such a dangerous habit - I had to watch a friend shatter his shoulder when the horse he was riding reared and flipped on him.
I don't give two hoots if it's pain, or fear, or whatever. Rearing is NEVER an acceptable action and all my horses know it. I holler for all i'm worth, get my heels or my spurs in, whip with my rein, whatever. As soon as they go forward, I stop, relax, and continue on.
After the fact, I will of course check for pain, etc. But during the fact, that doesn't even enter my mind.
However I like to avoid a rear ever happening by teaching my horses from the get go to be free in the feet and always have control of the feet.
If they do actually leave the ground (Not often, I have a pretty scary growl when I try!) I also crank that head to my knee and kick the hip over for all im' worth. If they do actually go up, I whale on them and keep them going in a tiny circle until they are puffing.
Not, EVER acceptable.