Permalink
Browse files

Updated license information and added namespace.

  • Loading branch information...
1 parent d87e1cc commit 306c87541362986b8d7d35ba3408375e9edd0d36 @samuelwilliams committed Sep 23, 2012
Showing with 22 additions and 30 deletions.
  1. +1 −1 LICENSE
  2. +9 −6 README.md
  3. +12 −23 eway.php → eWay.php
View
@@ -1,4 +1,4 @@
-Copyright (C) 2012 Sam Williams <sam@swilliams.com.au>
+Copyright (C) 2012 Sam Williams <sam@badcow.co>
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
View
@@ -1,16 +1,19 @@
-# eWay PHP API
+eWay PHP API
+============
-This class is designed to make eWay payments very easy. Details about the API can be found on the [eWay website](http://eway.com.au/developers/api/direct-payments.html)
+This class is designed to make eWay payments very easy. Details about the API can be found on the [eWay website](http://eway.com.au/developers/api/stored-\(xml\).html)
## Example usage
The example below utilises the eWay test gateway
- require_once('eway.php');
+ require_once __DIR__ . '/eWay/eWay.php';
- $eway = new eway('REAL_TIME_CVN', TRUE);
+ use Badcow\eWay\eWay;
- $eway
+ $eWay = new eWay('REAL_TIME_CVN', TRUE);
+
+ $eWay
->setCustomerID('87654321')
->setCardNumber('4444333322221111')
->setCardHoldersName('John Smith')
@@ -30,7 +33,7 @@ The example below utilises the eWay test gateway
->setOption3('Option Number Three')
;
- $eway->pay();
+ $eWay->pay();
Each setter method will return the eway class allowing for chaining.
View
@@ -1,27 +1,16 @@
<?php
-/**
-* Copyright (C) 2012 Sam Williams <sam@swilliams.com.au>
-*
-* Permission is hereby granted, free of charge, to any person obtaining a copy of
-* this software and associated documentation files (the "Software"), to deal in
-* the Software without restriction, including without limitation the rights to
-* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
-* of the Software, and to permit persons to whom the Software is furnished to do
-* so, subject to the following conditions:
-*
-* The above copyright notice and this permission notice shall be included in all
-* copies or substantial portions of the Software.
-*
-* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
-* SOFTWARE.
-*/
-
-class eway
+/*
+ * This file is part of the Membership Database.
+ *
+ * (c) 2012 Samuel Williams <sam@badcow.co>
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Badcow\eWay;
+
+class eWay
{
/**
* The gateway to use.

0 comments on commit 306c875

Please sign in to comment.