Я полностью согласен с Wrikken, не похоже, что вы отображали переменную во время процесса.Может быть, этот подход поможет:
<?php
print '<script src="http://maps.google.com/maps?file=api&v=2.x&key=';
$this->googleMapsApiKey = $this->getValueFromDB("google", "googleMapsApiKey");
switch ($_SERVER['HTTP_HOST'])
{
//Specific for a domain, but I think that the default handles it against your DB automatically
//case 'www.ABC.info' : $this->googleMapsApiKey = "Googlemap-keys";
// break;
//Same here
// case 'www.CBA.com': $this->googleMapsApiKey = "Googlemap-keys";
// break;
default: $this->googleMapsApiKey = "Googlemap-keys";
}
echo "$this->googleMapsApiKey type=\"text/javascript\"></script>";
?>