This commit is contained in:
abraar
2010-12-09 14:36:27 +00:00
parent 3ba050df76
commit 7cd504ddcc
4 changed files with 7 additions and 6 deletions

View File

@@ -9,7 +9,8 @@ function lookup($target)
{
global $ntarget;
$msg = $target . ' => ';
if( eregi('[a-zA-Z]', $target) )
//if( eregi('[a-zA-Z]', $target) )
if( preg_match('[a-zA-Z]', $target)) //Made compatible to PHP 5.3
$ntarget = gethostbyname($target);
else
$ntarget = gethostbyaddr($target);

View File

@@ -3911,7 +3911,7 @@ class XmlForm
$this->values [$k] = $newValues [$k];
}
foreach ( $this->fields as $k => $v ) {
if(get_class($this->fields[$k])!='__PHP_Incomplete_Class'){
if(is_object ($this->fields[$k]) && get_class($this->fields[$k])!='__PHP_Incomplete_Class'){
$this->fields [$k]->owner = & $this;
}

View File

@@ -93,7 +93,7 @@ class SOAP_Interop_Base {
function echoStruct($inputStruct)
{
if (strtolower(get_class($inputStruct)) == 'soapstruct') {
if (is_object($inputStruct) && strtolower(get_class($inputStruct)) == 'soapstruct') {
return $inputStruct->__to_soap();
}
return $inputStruct;

View File

@@ -178,7 +178,7 @@ class Interop_Client
if ($soap_test->headers) {
foreach ($soap_test->headers as $h) {
$destination = 0;
if (strtolower(get_class($h)) == 'soap_header') {
if (is_object($h) && strtolower(get_class($h)) == 'soap_header') {
if ($h->attributes['SOAP-ENV:actor'] == 'http://schemas.xmlsoap.org/soap/actor/next') {
$destination = 1;
}
@@ -383,7 +383,7 @@ class Interop_Client
// $header is already a SOAP_Header class
for ($i = 0, $hc = count($soap_test->headers); $i < $hc; $i++) {
$header = $soap_test->headers[$i];
if (strtolower(get_class($header)) != 'soap_header') {
if (is_object($header) && strtolower(get_class($header)) != 'soap_header') {
// Assume it's an array.
$header = new SOAP_Header($header[0], null, $header[1], $header[2], $header[3], $header[4]);
}
@@ -551,7 +551,7 @@ class Interop_Client
$thc = count($soap_test->headers);
for ($thi = 0; $thi < $thc; $thi++) {
$header = $soap_test->headers[$thi];
if (strtolower(get_class($header)) == 'soap_header') {
if (is_object($header) && strtolower(get_class($header)) == 'soap_header') {
if ($header->name == $m[2]) {
$gotit = $header->attributes['SOAP-ENV:actor'] == ($m[3] ? SOAP_TEST_ACTOR_NEXT : SOAP_TEST_ACTOR_OTHER);
$gotit = $gotit && $header->attributes['SOAP-ENV:mustUnderstand'] == $m[4];