diff options
author | Filipp Lepalaan <filipp@mac.com> | 2011-04-29 13:14:55 +0300 |
---|---|---|
committer | Filipp Lepalaan <filipp@mac.com> | 2011-04-29 13:14:55 +0300 |
commit | 30c626889bcaf69afdff190057b794f89970422c (patch) | |
tree | 79c141d88122b41285bbabd92dde338bb68f5185 | |
parent | 1663e0813a3629e01125c0eed65b735e068533df (diff) | |
download | gsxlib-30c626889bcaf69afdff190057b794f89970422c.tar.gz gsxlib-30c626889bcaf69afdff190057b794f89970422c.tar.bz2 gsxlib-30c626889bcaf69afdff190057b794f89970422c.zip |
some cleanup
-rw-r--r-- | README.md | 14 | ||||
-rw-r--r-- | gsxlib.php | 4 |
2 files changed, 9 insertions, 9 deletions
@@ -1,22 +1,26 @@ ##About## + GsxLib is a PHP library that simplifies communication with Apple's [GSX web service API][1]. It frees the application developer from knowing the underlying PHP SOAP architecture and to some extent even the GSX API itself. GsxLib also tries to provide some performance benefits by minimizing the number of requests made to the servers as well as doing some rudimentary input validation (as opposed to burdening Apple's servers with totally invalid requests). ##Requrements## + Your PHP should have SOAP support enabled. Most distributions should (including OS X Server 10.6 or later). For more details, consult your distribution or http://php.net/manual/en/book.soap.php. ##Usage## - <?php +Best illustrated with a simple example: + + <?php - include 'gsxlib/gsxlib.php'; - $gsx = new GsxLib('your sold-to account', 'gsx user', 'password'); - $info = $gsx->warrantyStatus('serialnumber'); + include 'gsxlib/gsxlib.php'; + $gsx = new GsxLib('your sold-to account', 'gsx user', 'password'); + $info = $gsx->warrantyStatus('serialnumber'); - ?> + ?> ##License## @@ -41,10 +41,6 @@ class GsxLib $wsdl = 'https://gsx'.$environment.'.apple.com/gsx-ws/services/'.$region.'/asp?wsdl'; $this->client = new SoapClient($wsdl, array('exceptions' => TRUE, 'trace' => 1)); - if (session_id()) { - $_SESSION['_gsxlib_client'] = serialize($this->client); - } - if (!$this->client) { exit('Failed to create SOAP client.'); } |