function rm_getHistoricQuotaSummaryPerPeriods($creditTypeId, $userId, $timeZoneId) { try { $client = new SoapClient(WSDL_QS, array('location' => LOCATION_QS)); $result = $client->getHistoricQuotaSummaryPerPeriods(array('creditTypeId' => $creditTypeId, 'userId' => $userId, 'timeZoneId' => $timeZoneId)); return $result->quotaSummary; } catch (Exception $e) { return array("success" => false, "message" => $e->getMessage()); } catch (SoapFault $soapfault) { return array("success" => false, "message" => $soapfault->getMessage()); } }