@@ 1004-1016 (lines=13) @@ | ||
1001 | $this->xh[$the_parser]['value'] = FALSE; |
|
1002 | } |
|
1003 | } |
|
1004 | elseif ($name == 'DOUBLE') |
|
1005 | { |
|
1006 | // we have a DOUBLE |
|
1007 | // we must check that only 0123456789-.<space> are characters here |
|
1008 | if ( ! preg_match('/^[+-]?[eE0-9\t \.]+$/', $this->xh[$the_parser]['ac'])) |
|
1009 | { |
|
1010 | $this->xh[$the_parser]['value'] = 'ERROR_NON_NUMERIC_FOUND'; |
|
1011 | } |
|
1012 | else |
|
1013 | { |
|
1014 | $this->xh[$the_parser]['value'] = (double)$this->xh[$the_parser]['ac']; |
|
1015 | } |
|
1016 | } |
|
1017 | else |
|
1018 | { |
|
1019 | // we have an I4/INT |
|
@@ 1017-1029 (lines=13) @@ | ||
1014 | $this->xh[$the_parser]['value'] = (double)$this->xh[$the_parser]['ac']; |
|
1015 | } |
|
1016 | } |
|
1017 | else |
|
1018 | { |
|
1019 | // we have an I4/INT |
|
1020 | // we must check that only 0123456789-<space> are characters here |
|
1021 | if ( ! preg_match('/^[+-]?[0-9\t ]+$/', $this->xh[$the_parser]['ac'])) |
|
1022 | { |
|
1023 | $this->xh[$the_parser]['value'] = 'ERROR_NON_NUMERIC_FOUND'; |
|
1024 | } |
|
1025 | else |
|
1026 | { |
|
1027 | $this->xh[$the_parser]['value'] = (int)$this->xh[$the_parser]['ac']; |
|
1028 | } |
|
1029 | } |
|
1030 | $this->xh[$the_parser]['ac'] = ''; |
|
1031 | $this->xh[$the_parser]['lv'] = 3; // indicate we've found a value |
|
1032 | break; |
|
@@ 1035-1039 (lines=5) @@ | ||
1032 | break; |
|
1033 | case 'VALUE': |
|
1034 | // This if() detects if no scalar was inside <VALUE></VALUE> |
|
1035 | if ($this->xh[$the_parser]['vt'] == 'value') |
|
1036 | { |
|
1037 | $this->xh[$the_parser]['value'] = $this->xh[$the_parser]['ac']; |
|
1038 | $this->xh[$the_parser]['vt'] = $this->xmlrpcString; |
|
1039 | } |
|
1040 | ||
1041 | // build the XML-RPC value out of the data received, and substitute it |
|
1042 | $temp = new XML_RPC_Values($this->xh[$the_parser]['value'], $this->xh[$the_parser]['vt']); |