We have a very weird problem with one of sites running WordPress. Suddenly, TinyMCE visual editor stopped working. It just disappeared, and we only got the weird:
realTinyMCE is not defined
error in the console.
Of course visual editor was turned on in users preferences and all that stuff. Switching to a different theme was solving the problem.
Turned out that the problem was in the functions.php file which was located in WordPress current theme's directory. And the reason was the most weird one you can imagine! We had several excessive line breaks after the php closing tag!!
Have a look at these pictures:

Take notice of these 2 excessive line breaks after the closing tag of the functions.php file.
Just remove them…

And everything's back to normal again!
So, check that the functions.php file in your current WordPress theme doesn't have any excessive line breaks after the closing php tag.