"Did you say it to him or to her?"
Translation:Řekli jste to jemu nebo jí?
"Mu" is just a clitic form of "jemu". "Mu" (and other clitics) usually has the second position after the first part of a sentence.
How about "Řekli jste mu nebo jí to"? I think "Řekli jste mu to" is correct at least? This is so hard :)
No, that is impossible. Here we ask if it is him or her, the pronouns are stressed, you cannot use the short forms.