@@ -944,12 +944,12 @@ discard block |
||
| 944 | 944 | } |
| 945 | 945 | if ($utc) { |
| 946 | 946 | $pattern = '/' . |
| 947 | - '([0-9]{4})-' . // centuries & years CCYY- |
|
| 948 | - '([0-9]{2})-' . // months MM- |
|
| 949 | - '([0-9]{2})' . // days DD |
|
| 950 | - 'T' . // separator T |
|
| 951 | - '([0-9]{2}):' . // hours hh: |
|
| 952 | - '([0-9]{2}):' . // minutes mm: |
|
| 947 | + '([0-9]{4})-' . // centuries & years CCYY- |
|
| 948 | + '([0-9]{2})-' . // months MM- |
|
| 949 | + '([0-9]{2})' . // days DD |
|
| 950 | + 'T' . // separator T |
|
| 951 | + '([0-9]{2}):' . // hours hh: |
|
| 952 | + '([0-9]{2}):' . // minutes mm: |
|
| 953 | 953 | '([0-9]{2})(\.[0-9]*)?' . // seconds ss.ss... |
| 954 | 954 | '(Z|[+\-][0-9]{2}:?[0-9]{2})?' . // Z to indicate UTC, -/+HH:MM:SS.SS... for local tz's |
| 955 | 955 | '/'; |
@@ -973,12 +973,12 @@ discard block |
||
| 973 | 973 | function iso8601_to_timestamp($datestr) |
| 974 | 974 | { |
| 975 | 975 | $pattern = '/' . |
| 976 | - '([0-9]{4})-' . // centuries & years CCYY- |
|
| 977 | - '([0-9]{2})-' . // months MM- |
|
| 978 | - '([0-9]{2})' . // days DD |
|
| 979 | - 'T' . // separator T |
|
| 980 | - '([0-9]{2}):' . // hours hh: |
|
| 981 | - '([0-9]{2}):' . // minutes mm: |
|
| 976 | + '([0-9]{4})-' . // centuries & years CCYY- |
|
| 977 | + '([0-9]{2})-' . // months MM- |
|
| 978 | + '([0-9]{2})' . // days DD |
|
| 979 | + 'T' . // separator T |
|
| 980 | + '([0-9]{2}):' . // hours hh: |
|
| 981 | + '([0-9]{2}):' . // minutes mm: |
|
| 982 | 982 | '([0-9]{2})(\.[0-9]+)?' . // seconds ss.ss... |
| 983 | 983 | '(Z|[+\-][0-9]{2}:?[0-9]{2})?' . // Z to indicate UTC, -/+HH:MM:SS.SS... for local tz's |
| 984 | 984 | '/'; |
@@ -1016,7 +1016,7 @@ discard block |
||
| 1016 | 1016 | |
| 1017 | 1017 | do { |
| 1018 | 1018 | $stop = gettimeofday(); |
| 1019 | - $timePassed = 1000000 * ($stop['sec'] - $start['sec']) |
|
| 1019 | + $timePassed = 1000000*($stop['sec'] - $start['sec']) |
|
| 1020 | 1020 | + $stop['usec'] - $start['usec']; |
| 1021 | 1021 | } while ($timePassed < $usec); |
| 1022 | 1022 | } |
@@ -2232,18 +2232,18 @@ discard block |
||
| 2232 | 2232 | var $incoming_cookies = array(); |
| 2233 | 2233 | var $outgoing_payload = ''; |
| 2234 | 2234 | var $incoming_payload = ''; |
| 2235 | - var $response_status_line; // HTTP response status line |
|
| 2235 | + var $response_status_line; // HTTP response status line |
|
| 2236 | 2236 | var $useSOAPAction = true; |
| 2237 | 2237 | var $persistentConnection = false; |
| 2238 | - var $ch = false; // cURL handle |
|
| 2239 | - var $ch_options = array(); // cURL custom options |
|
| 2240 | - var $use_curl = false; // force cURL use |
|
| 2241 | - var $proxy = null; // proxy information (associative array) |
|
| 2238 | + var $ch = false; // cURL handle |
|
| 2239 | + var $ch_options = array(); // cURL custom options |
|
| 2240 | + var $use_curl = false; // force cURL use |
|
| 2241 | + var $proxy = null; // proxy information (associative array) |
|
| 2242 | 2242 | var $username = ''; |
| 2243 | 2243 | var $password = ''; |
| 2244 | 2244 | var $authtype = ''; |
| 2245 | 2245 | var $digestRequest = array(); |
| 2246 | - var $certRequest = array(); // keys must be cainfofile (optional), sslcertfile, sslkeyfile, passphrase, certpassword (optional), verifypeer (optional), verifyhost (optional) |
|
| 2246 | + var $certRequest = array(); // keys must be cainfofile (optional), sslcertfile, sslkeyfile, passphrase, certpassword (optional), verifypeer (optional), verifyhost (optional) |
|
| 2247 | 2247 | // cainfofile: certificate authority file, e.g. '$pathToPemFiles/rootca.pem' |
| 2248 | 2248 | // sslcertfile: SSL certificate file, e.g. '$pathToPemFiles/mycert.pem' |
| 2249 | 2249 | // sslkeyfile: SSL key file, e.g. '$pathToPemFiles/mykey.pem' |
@@ -3098,7 +3098,7 @@ discard block |
||
| 3098 | 3098 | |
| 3099 | 3099 | // loop until msg has been received |
| 3100 | 3100 | if (isset($this->incoming_headers['transfer-encoding']) && strtolower($this->incoming_headers['transfer-encoding']) == 'chunked') { |
| 3101 | - $content_length = 2147483647; // ignore any content-length header |
|
| 3101 | + $content_length = 2147483647; // ignore any content-length header |
|
| 3102 | 3102 | $chunked = true; |
| 3103 | 3103 | $this->debug("want to read chunked content"); |
| 3104 | 3104 | } elseif (isset($this->incoming_headers['content-length'])) { |
@@ -4189,13 +4189,13 @@ discard block |
||
| 4189 | 4189 | } else { |
| 4190 | 4190 | if ($class == '') { |
| 4191 | 4191 | $this->debug('in invoke_method, calling function using call_user_func_array()'); |
| 4192 | - $call_arg = "$this->methodname"; // straight assignment changes $this->methodname to lower case after call_user_func_array() |
|
| 4192 | + $call_arg = "$this->methodname"; // straight assignment changes $this->methodname to lower case after call_user_func_array() |
|
| 4193 | 4193 | } elseif ($delim == '..') { |
| 4194 | 4194 | $this->debug('in invoke_method, calling class method using call_user_func_array()'); |
| 4195 | 4195 | $call_arg = array($class, $method); |
| 4196 | 4196 | } else { |
| 4197 | 4197 | $this->debug('in invoke_method, calling instance method using call_user_func_array()'); |
| 4198 | - $instance = new $class (); |
|
| 4198 | + $instance = new $class(); |
|
| 4199 | 4199 | $call_arg = array(&$instance, $method); |
| 4200 | 4200 | } |
| 4201 | 4201 | if (is_array($this->methodparams)) { |
@@ -4753,13 +4753,13 @@ discard block |
||
| 4753 | 4753 | var $proxypassword = ''; |
| 4754 | 4754 | var $timeout = 0; |
| 4755 | 4755 | var $response_timeout = 30; |
| 4756 | - var $curl_options = array(); // User-specified cURL options |
|
| 4757 | - var $use_curl = false; // whether to always try to use cURL |
|
| 4756 | + var $curl_options = array(); // User-specified cURL options |
|
| 4757 | + var $use_curl = false; // whether to always try to use cURL |
|
| 4758 | 4758 | // for HTTP authentication |
| 4759 | - var $username = ''; // Username for HTTP authentication |
|
| 4760 | - var $password = ''; // Password for HTTP authentication |
|
| 4761 | - var $authtype = ''; // Type of HTTP authentication |
|
| 4762 | - var $certRequest = array(); // Certificate for HTTP SSL authentication |
|
| 4759 | + var $username = ''; // Username for HTTP authentication |
|
| 4760 | + var $password = ''; // Password for HTTP authentication |
|
| 4761 | + var $authtype = ''; // Type of HTTP authentication |
|
| 4762 | + var $certRequest = array(); // Certificate for HTTP SSL authentication |
|
| 4763 | 4763 | |
| 4764 | 4764 | /** |
| 4765 | 4765 | * constructor |
@@ -4814,7 +4814,7 @@ discard block |
||
| 4814 | 4814 | // Schema imports |
| 4815 | 4815 | foreach ($this->schemas as $ns => $list) { |
| 4816 | 4816 | foreach ($list as $xs) { |
| 4817 | - $wsdlparts = parse_url($this->wsdl); // this is bogusly simple! |
|
| 4817 | + $wsdlparts = parse_url($this->wsdl); // this is bogusly simple! |
|
| 4818 | 4818 | foreach ($xs->imports as $ns2 => $list2) { |
| 4819 | 4819 | for ($ii = 0; $ii < count($list2); $ii++) { |
| 4820 | 4820 | if (!$list2[$ii]['loaded']) { |
@@ -4840,7 +4840,7 @@ discard block |
||
| 4840 | 4840 | } |
| 4841 | 4841 | } |
| 4842 | 4842 | // WSDL imports |
| 4843 | - $wsdlparts = parse_url($this->wsdl); // this is bogusly simple! |
|
| 4843 | + $wsdlparts = parse_url($this->wsdl); // this is bogusly simple! |
|
| 4844 | 4844 | foreach ($this->import as $ns => $list) { |
| 4845 | 4845 | for ($ii = 0; $ii < count($list); $ii++) { |
| 4846 | 4846 | if (!$list[$ii]['loaded']) { |
@@ -4871,12 +4871,10 @@ discard block |
||
| 4871 | 4871 | $this->debug('post-parse data gathering for ' . $operation); |
| 4872 | 4872 | $this->bindings[$binding]['operations'][$operation]['input'] = |
| 4873 | 4873 | isset($this->bindings[$binding]['operations'][$operation]['input']) ? |
| 4874 | - array_merge($this->bindings[$binding]['operations'][$operation]['input'], $this->portTypes[$bindingData['portType']][$operation]['input']) : |
|
| 4875 | - $this->portTypes[$bindingData['portType']][$operation]['input']; |
|
| 4874 | + array_merge($this->bindings[$binding]['operations'][$operation]['input'], $this->portTypes[$bindingData['portType']][$operation]['input']) : $this->portTypes[$bindingData['portType']][$operation]['input']; |
|
| 4876 | 4875 | $this->bindings[$binding]['operations'][$operation]['output'] = |
| 4877 | 4876 | isset($this->bindings[$binding]['operations'][$operation]['output']) ? |
| 4878 | - array_merge($this->bindings[$binding]['operations'][$operation]['output'], $this->portTypes[$bindingData['portType']][$operation]['output']) : |
|
| 4879 | - $this->portTypes[$bindingData['portType']][$operation]['output']; |
|
| 4877 | + array_merge($this->bindings[$binding]['operations'][$operation]['output'], $this->portTypes[$bindingData['portType']][$operation]['output']) : $this->portTypes[$bindingData['portType']][$operation]['output']; |
|
| 4880 | 4878 | if (isset($this->messages[$this->bindings[$binding]['operations'][$operation]['input']['message']])) { |
| 4881 | 4879 | $this->bindings[$binding]['operations'][$operation]['input']['parts'] = $this->messages[$this->bindings[$binding]['operations'][$operation]['input']['message']]; |
| 4882 | 4880 | } |
@@ -6684,7 +6682,7 @@ discard block |
||
| 6684 | 6682 | var $root_struct_name = ''; |
| 6685 | 6683 | var $root_struct_namespace = ''; |
| 6686 | 6684 | var $root_header = ''; |
| 6687 | - var $document = ''; // incoming SOAP body (text) |
|
| 6685 | + var $document = ''; // incoming SOAP body (text) |
|
| 6688 | 6686 | // determines where in the message we are (envelope,header,body,method) |
| 6689 | 6687 | var $status = ''; |
| 6690 | 6688 | var $position = 0; |
@@ -6699,9 +6697,9 @@ discard block |
||
| 6699 | 6697 | var $fault_detail = ''; |
| 6700 | 6698 | var $depth_array = array(); |
| 6701 | 6699 | var $debug_flag = true; |
| 6702 | - var $soapresponse = null; // parsed SOAP Body |
|
| 6703 | - var $soapheader = null; // parsed SOAP Header |
|
| 6704 | - var $responseHeaders = ''; // incoming SOAP headers (text) |
|
| 6700 | + var $soapresponse = null; // parsed SOAP Body |
|
| 6701 | + var $soapheader = null; // parsed SOAP Header |
|
| 6702 | + var $responseHeaders = ''; // incoming SOAP headers (text) |
|
| 6705 | 6703 | var $body_position = 0; |
| 6706 | 6704 | // for multiref parsing: |
| 6707 | 6705 | // array of id => pos |
@@ -6994,7 +6992,7 @@ discard block |
||
| 6994 | 6992 | // add placeholder to href array |
| 6995 | 6993 | $this->multirefs[$id][$pos] = 'placeholder'; |
| 6996 | 6994 | // add set a reference to it as the result value |
| 6997 | - $this->message[$pos]['result'] =& $this->multirefs[$id][$pos]; |
|
| 6995 | + $this->message[$pos]['result'] = & $this->multirefs[$id][$pos]; |
|
| 6998 | 6996 | // build complexType values |
| 6999 | 6997 | } elseif ($this->message[$pos]['children'] != '') { |
| 7000 | 6998 | // if result has already been generated (struct/array) |
@@ -7340,37 +7338,37 @@ discard block |
||
| 7340 | 7338 | class nusoap_client extends nusoap_base |
| 7341 | 7339 | { |
| 7342 | 7340 | |
| 7343 | - var $username = ''; // Username for HTTP authentication |
|
| 7344 | - var $password = ''; // Password for HTTP authentication |
|
| 7345 | - var $authtype = ''; // Type of HTTP authentication |
|
| 7346 | - var $certRequest = array(); // Certificate for HTTP SSL authentication |
|
| 7347 | - var $requestHeaders = false; // SOAP headers in request (text) |
|
| 7348 | - var $responseHeaders = ''; // SOAP headers from response (incomplete namespace resolution) (text) |
|
| 7349 | - var $responseHeader = null; // SOAP Header from response (parsed) |
|
| 7350 | - var $document = ''; // SOAP body response portion (incomplete namespace resolution) (text) |
|
| 7341 | + var $username = ''; // Username for HTTP authentication |
|
| 7342 | + var $password = ''; // Password for HTTP authentication |
|
| 7343 | + var $authtype = ''; // Type of HTTP authentication |
|
| 7344 | + var $certRequest = array(); // Certificate for HTTP SSL authentication |
|
| 7345 | + var $requestHeaders = false; // SOAP headers in request (text) |
|
| 7346 | + var $responseHeaders = ''; // SOAP headers from response (incomplete namespace resolution) (text) |
|
| 7347 | + var $responseHeader = null; // SOAP Header from response (parsed) |
|
| 7348 | + var $document = ''; // SOAP body response portion (incomplete namespace resolution) (text) |
|
| 7351 | 7349 | var $endpoint; |
| 7352 | - var $forceEndpoint = ''; // overrides WSDL endpoint |
|
| 7350 | + var $forceEndpoint = ''; // overrides WSDL endpoint |
|
| 7353 | 7351 | var $proxyhost = ''; |
| 7354 | 7352 | var $proxyport = ''; |
| 7355 | 7353 | var $proxyusername = ''; |
| 7356 | 7354 | var $proxypassword = ''; |
| 7357 | - var $portName = ''; // port name to use in WSDL |
|
| 7358 | - var $xml_encoding = ''; // character set encoding of incoming (response) messages |
|
| 7355 | + var $portName = ''; // port name to use in WSDL |
|
| 7356 | + var $xml_encoding = ''; // character set encoding of incoming (response) messages |
|
| 7359 | 7357 | var $http_encoding = false; |
| 7360 | - var $timeout = 0; // HTTP connection timeout |
|
| 7361 | - var $response_timeout = 30; // HTTP response timeout |
|
| 7362 | - var $endpointType = ''; // soap|wsdl, empty for WSDL initialization error |
|
| 7358 | + var $timeout = 0; // HTTP connection timeout |
|
| 7359 | + var $response_timeout = 30; // HTTP response timeout |
|
| 7360 | + var $endpointType = ''; // soap|wsdl, empty for WSDL initialization error |
|
| 7363 | 7361 | var $persistentConnection = false; |
| 7364 | - var $defaultRpcParams = false; // This is no longer used |
|
| 7365 | - var $request = ''; // HTTP request |
|
| 7366 | - var $response = ''; // HTTP response |
|
| 7367 | - var $responseData = ''; // SOAP payload of response |
|
| 7368 | - var $cookies = array(); // Cookies from response or for request |
|
| 7369 | - var $decode_utf8 = true; // toggles whether the parser decodes element content w/ utf8_decode() |
|
| 7370 | - var $operations = array(); // WSDL operations, empty for WSDL initialization error |
|
| 7371 | - var $curl_options = array(); // User-specified cURL options |
|
| 7372 | - var $bindingType = ''; // WSDL operation binding type |
|
| 7373 | - var $use_curl = false; // whether to always try to use cURL |
|
| 7362 | + var $defaultRpcParams = false; // This is no longer used |
|
| 7363 | + var $request = ''; // HTTP request |
|
| 7364 | + var $response = ''; // HTTP response |
|
| 7365 | + var $responseData = ''; // SOAP payload of response |
|
| 7366 | + var $cookies = array(); // Cookies from response or for request |
|
| 7367 | + var $decode_utf8 = true; // toggles whether the parser decodes element content w/ utf8_decode() |
|
| 7368 | + var $operations = array(); // WSDL operations, empty for WSDL initialization error |
|
| 7369 | + var $curl_options = array(); // User-specified cURL options |
|
| 7370 | + var $bindingType = ''; // WSDL operation binding type |
|
| 7371 | + var $use_curl = false; // whether to always try to use cURL |
|
| 7374 | 7372 | |
| 7375 | 7373 | /* |
| 7376 | 7374 | * fault related variables |
@@ -7746,7 +7744,7 @@ discard block |
||
| 7746 | 7744 | case preg_match('/^http/', $this->endpoint): |
| 7747 | 7745 | $this->debug('transporting via HTTP'); |
| 7748 | 7746 | if ($this->persistentConnection == true && is_object($this->persistentConnection)) { |
| 7749 | - $http =& $this->persistentConnection; |
|
| 7747 | + $http = & $this->persistentConnection; |
|
| 7750 | 7748 | } else { |
| 7751 | 7749 | $http = new soap_transport_http($this->endpoint, $this->curl_options, $this->use_curl); |
| 7752 | 7750 | if ($this->persistentConnection) { |
@@ -44,21 +44,21 @@ |
||
| 44 | 44 | global $SubscriptionId; |
| 45 | 45 | |
| 46 | 46 | // create items to be added to the cart |
| 47 | - $item = array (); |
|
| 48 | - $item[0] = array( "ASIN" => "0596004206", |
|
| 47 | + $item = array(); |
|
| 48 | + $item[0] = array("ASIN" => "0596004206", |
|
| 49 | 49 | "Quantity" => "1" |
| 50 | 50 | ); |
| 51 | - $item[1] = array( "ASIN" => "0596003277", |
|
| 51 | + $item[1] = array("ASIN" => "0596003277", |
|
| 52 | 52 | "Quantity" => "2" |
| 53 | 53 | ); |
| 54 | 54 | |
| 55 | 55 | // pack it to <Item> array |
| 56 | - $items = array("Item" => $item); |
|
| 56 | + $items = array("Item" => $item); |
|
| 57 | 57 | // Construct request parameters |
| 58 | 58 | $request = array("Items" => $items, "ResponseGroup" => "CartSimilarities"); |
| 59 | 59 | |
| 60 | 60 | // Construct all parameters |
| 61 | - $cartCreate = array( "SubscriptionId" => $SubscriptionId, |
|
| 61 | + $cartCreate = array("SubscriptionId" => $SubscriptionId, |
|
| 62 | 62 | "Request" => $request |
| 63 | 63 | ); |
| 64 | 64 | |
@@ -25,10 +25,10 @@ |
||
| 25 | 25 | */ |
| 26 | 26 | if ($method == '') { |
| 27 | 27 | echo '<form name="MethodForm" method="POST">'; |
| 28 | - echo '<input type="hidden" name="proxyhost" value="' . $proxyhost .'">'; |
|
| 29 | - echo '<input type="hidden" name="proxyport" value="' . $proxyport .'">'; |
|
| 30 | - echo '<input type="hidden" name="proxyusername" value="' . $proxyusername .'">'; |
|
| 31 | - echo '<input type="hidden" name="proxypassword" value="' . $proxypassword .'">'; |
|
| 28 | + echo '<input type="hidden" name="proxyhost" value="' . $proxyhost . '">'; |
|
| 29 | + echo '<input type="hidden" name="proxyport" value="' . $proxyport . '">'; |
|
| 30 | + echo '<input type="hidden" name="proxyusername" value="' . $proxyusername . '">'; |
|
| 31 | + echo '<input type="hidden" name="proxypassword" value="' . $proxypassword . '">'; |
|
| 32 | 32 | echo 'Method: <select name="method">'; |
| 33 | 33 | echo '<option>echoString</option>'; |
| 34 | 34 | echo '<option>echoStringArray</option>'; |