i use the following method:
the "live" version's url is called like this:
www.thesite.com
and the alternative way is:
develop.mycompany.com/customers/thesite
now, if you enter via develop.... (for developing), have your php script(s) check the host (you can read it out) and suppress error messages only if the host is www.
this works fine here:
$host = $HTTP_HOST;
$parts = explode(".", $host);
$host = $parts[0];
if($host == "www")
{
// suppress error messages settings
}