No, the enemy would not be able to totally control an ally with Charm Person
That's the realm of Dominate Person.
First, we need to clear up some of your statements:
Does the charmed person fight against it's former allies?
These are not your former allies, they're still your allies. You just happened to have gained a new close friend.
Does the charmed person fight against it's former allies? What does it do seeing the
former allies fighting the new allies?
What would you do if two of your very close friends got into a fight to the death? You'd probably try to break it up, wouldn't you? You may or may not pick a side in the fight, but you're not likely to want to hurt either of your very good friends.
Wouldn't it be strange, my new best friend was some seconds before my worst enemy?
Heck yes it would, but the spell changes your behavior so that doesn't matter.
Now onto the relevant parts of the spell. From the PRD:
This charm makes a humanoid creature regard you as its trusted friend
and ally (treat the target's attitude as friendly). If the creature is
currently being threatened or attacked by you or your allies, however,
it receives a +5 bonus on its saving throw.
The spell does not enable you to control the charmed person as if it
were an automaton, but it perceives your words and actions in the most
favorable way. You can try to give the subject orders, but you must
win an opposed Charisma check to convince it to do anything it
wouldn't ordinarily do. (Retries are not allowed.) An affected
creature never obeys suicidal or obviously harmful orders, but it
might be convinced that something very dangerous is worth doing. Any
act by you or your apparent allies that threatens the charmed person
breaks the spell. You must speak the person's language to communicate
your commands, or else be good at pantomiming.
So, what happens if the person who cast the charm spell managed to win the Charisma check against you to make you attack your friends? You'd probably do it, but would likely not want to kill them, just make them stop fighting your buddy.