Cleanup some globals, commented crap

This commit is contained in:
Miles Lott 2002-01-29 00:48:03 +00:00
parent 99ff77322a
commit 30684926fe
7 changed files with 6 additions and 26 deletions

View File

@ -35,7 +35,7 @@
function browser ()
{
global $HTTP_USER_AGENT;
$HTTP_USER_AGENT = $GLOBALS['HTTP_USER_AGENT'];
/*
Determine browser and version
*/

View File

@ -81,11 +81,9 @@
return;
}
global $HTTP_POST_VARS;
if (is_array($HTTP_POST_VARS))
if (is_array($GLOBALS['HTTP_POST_VARS']))
{
while( list($key, $val) = each($HTTP_POST_VARS))
while( list($key, $val) = each($GLOBALS['HTTP_POST_VARS']))
{
if (ereg("(.*)_x",$key,$varName) && $HTTP_POST_VARS[$varName[1]."_y"])
{

View File

@ -100,7 +100,6 @@
*/
function link($url = '', $extravars = '')
{
/* global $phpgw, $phpgw_info, $usercookie, $kp3, $PHP_SELF; */
return $this->session->link($url, $extravars);
}
@ -116,8 +115,6 @@
*/
function redirect($url = '')
{
/* global $HTTP_ENV_VARS; */
$iis = @strpos($GLOBALS['HTTP_ENV_VARS']['SERVER_SOFTWARE'], 'IIS', 0);
if ( !$url )
@ -156,7 +153,6 @@
*/
function lang($key, $m1 = '', $m2 = '', $m3 = '', $m4 = '')
{
/* global $phpgw; */
return $this->translation->translate($key);
}
} /* end of class */

View File

@ -5,9 +5,7 @@
{
function soap_parser($xml='',$encoding='UTF-8')
{
global $soapTypes;
$this->soapTypes = $soapTypes;
$this->soapTypes = $GLOBALS['soapTypes'];
$this->xml = $xml;
$this->xml_encoding = $encoding;
$this->root_struct = "";

View File

@ -431,9 +431,6 @@
{
if ($type)
{
// global $GLOBALS['namespaces'],$GLOBALS['soapTypes'],$GLOBALS['typemap'];
// global $GLOBALS['namespaces'],$GLOBALS['typemap'];
@reset($GLOBALS['typemap']);
while(list($namespace,$types) = @each($GLOBALS['typemap']))
/* foreach($GLOBALS['typemap'] as $namespace => $types) */

View File

@ -43,8 +43,6 @@
function xmlrpc_server($dispMap='', $serviceNow=0)
{
global $HTTP_RAW_POST_DATA;
// dispMap is a despatch array of methods
// mapped to function names and signatures
// if a method
@ -74,8 +72,6 @@
function service()
{
global $HTTP_RAW_POST_DATA;
$r = $this->parseRequest();
$payload = "<?xml version=\"1.0\"?>\n" . $this->serializeDebug() . $r->serialize();
Header("Content-type: text/xml\r\nContent-length: " . strlen($payload));
@ -226,11 +222,9 @@
function parseRequest($data='')
{
global $HTTP_RAW_POST_DATA;
if ($data == '')
{
$data = $HTTP_RAW_POST_DATA;
$data = $GLOBALS['HTTP_RAW_POST_DATA'];
}
$parser = xml_parser_create($GLOBALS['xmlrpc_defencoding']);
@ -430,12 +424,10 @@
function echoInput()
{
global $HTTP_RAW_POST_DATA;
// a debugging routine: just echos back the input
// packet as a string value
$r = CreateObject('phpgwapi.xmlrpcresp',CreateObject('phpgwapi.xmlrpcval',"'Aha said I: '" . $HTTP_RAW_POST_DATA,'string'));
$r = CreateObject('phpgwapi.xmlrpcresp',CreateObject('phpgwapi.xmlrpcval',"'Aha said I: '" . $GLOBALS['HTTP_RAW_POST_DATA'],'string'));
echo $r->serialize();
}
}

View File

@ -108,7 +108,6 @@
function addStruct($vals)
{
// global $xmlrpcTypes;
if ($this->mytype!=0)
{
echo '<B>xmlrpcval</B>: already initialized as a [' . $this->kindOf() . ']<BR>';