function phpAds_getZoneName($zoneid) { $conf = $GLOBALS['_MAX']['CONF']; global $zoneCache; global $strUntitled; if ($zoneid != '' && $zoneid != 0) { if (isset($zoneCache[$zoneid]) && is_array($zoneCache[$zoneid])) { $row = $zoneCache[$zoneid]; } else { $doZones = OA_Dal::staticGetDO('zones', $zoneid); $zoneCache[$zoneid] = $doZones->toArray(); } return phpAds_BuildZoneName($zoneid, $row['zonename']); } else { return $strUntitled; } }
function phpAds_getZoneName($zoneid, $html = true) { global $phpAds_config; global $zoneCache; global $strUntitled; if ($zoneid != '' && $zoneid != 0) { if (isset($zoneCache[$zoneid]) && is_array($zoneCache[$zoneid])) { $row = $zoneCache[$zoneid]; } else { $res = phpAds_dbQuery("\n\t\t\tSELECT\n\t\t\t\t*\n\t\t\tFROM\n\t\t\t\t" . $phpAds_config['tbl_zones'] . "\n\t\t\tWHERE\n\t\t\t\tzoneid = '{$zoneid}'\n\t\t\t") or phpAds_sqlDie(); $row = phpAds_dbFetchArray($res); $zoneCache[$zoneid] = $row; } return phpAds_BuildZoneName($zoneid, $row['zonename'], $html); } else { return $strUntitled; } }