I know this thread is a few weeks old, but I just wanted to make a suggestion. To avoid having this sort of thing happen to you in the future I would strongly recommend having a development environment that is separate from your production environment.
You should have a totally separate server identical to your production setup where you test your changes on first, and when you've confirmed that they work you should push those changes to production using a version control system. I personally use Mercurial for this, but there are a variety of others.
With a system like this you can safely make changes to the development version of your site without worrying about breaking the public-facing site, and if any of the changes you push to production from development break something you can always roll them back.
This is pretty much how all professional web developers worth their salt operate. No good developer makes changes directly to their production environment unless its something really minor and they're absolutely certain that it won't break anything (and even then, it's still not recommended)