SitePoint Sponsor

User Tag List

Results 1 to 11 of 11
  1. #1
    Knowledge is key 2 progression Tryst's Avatar
    Join Date
    Sep 2003
    Location
    Wales
    Posts
    1,181
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Custom Built Shopping Cart Integration with a Merchant Account

    Hi all,

    I am gonna to start building a shopping cart that will obviously be integrated to a processing gateway when finished, and am wondering whether I might come across any problems when attempting to integrate the shopping cart and processing gatway together.

    Do I have to consider any incompatibily problems that may arise through the merchant processing gateway?

    Cheers

    Tryst

  2. #2
    He's No Good To Me Dead silver trophybronze trophy stymiee's Avatar
    Join Date
    Feb 2003
    Location
    Slave I
    Posts
    23,423
    Mentioned
    2 Post(s)
    Tagged
    1 Thread(s)
    Each Gateway has their own API that needs to be addressed. If you plan you work with only one Gateway, you can custom write your software to work with it specifically. If you plan to support all of the major gateways, and more, you'll need to write your code modularly so you can accomodate the gateway being used.

  3. #3
    Knowledge is key 2 progression Tryst's Avatar
    Join Date
    Sep 2003
    Location
    Wales
    Posts
    1,181
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    But each/any shopping cart will only really be passing a set of parameters to gateway, so as long as I ensure that these parameters are passed to a gateway my shopping cart should be fine with most gateways, shouldn't it?

    Cheers

    Tryst

  4. #4
    He's No Good To Me Dead silver trophybronze trophy stymiee's Avatar
    Join Date
    Feb 2003
    Location
    Slave I
    Posts
    23,423
    Mentioned
    2 Post(s)
    Tagged
    1 Thread(s)
    Each gateway will expect those parameters in different ways. As long as you send them in the right format, you're in good shape.

  5. #5
    Knowledge is key 2 progression Tryst's Avatar
    Join Date
    Sep 2003
    Location
    Wales
    Posts
    1,181
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    OK, cheers,

    So should I find out what gateway provider I shall be using and what format they expect parameters before I actually start implementing the shopping cart?

    Tryst

  6. #6
    He's No Good To Me Dead silver trophybronze trophy stymiee's Avatar
    Join Date
    Feb 2003
    Location
    Slave I
    Posts
    23,423
    Mentioned
    2 Post(s)
    Tagged
    1 Thread(s)
    Not a bad idea. You'll need to know it at some point but it won't actually come into play until you actually write the transaction portion of the cart. It couldn't hurt to start reading up on it now so by the time you get that far you'll already have a game plan.

  7. #7
    Knowledge is key 2 progression Tryst's Avatar
    Join Date
    Sep 2003
    Location
    Wales
    Posts
    1,181
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    OK, cheers, stymiee

    Tryst

  8. #8
    He's No Good To Me Dead silver trophybronze trophy stymiee's Avatar
    Join Date
    Feb 2003
    Location
    Slave I
    Posts
    23,423
    Mentioned
    2 Post(s)
    Tagged
    1 Thread(s)
    Anytime

  9. #9
    SitePoint Addict
    Join Date
    Mar 2004
    Location
    Grand Junction, CO
    Posts
    292
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    You would want the part of the shopping cart that interacts with the gateway to be pretty modular. I don't know what language you'll use to do this, but I'm assuming PHP since that's what everybody uses now. Except me I don't know if PHP has the concept of interfaces, but you would want to do something like that.

    Come up with an API of your own, that is contained within your application. authenticate_user(), sendCCDetails(), etc, whatever you need. Just make those methods skeleton code - an output in each statement would be fine. Build the sytem to use this API, so it's not reliant upon the underlying gateway. Then you can create a new class for each gateway and substitute it in appropriately. This would let you sell the shopping cart later on, hyping the fact that it's compatible with all the major gateways, and extensible so you can add support for the rest if customers need. It will also help simplify your application code, as well as provide all the other benefits of good, modularized program design.

  10. #10
    Knowledge is key 2 progression Tryst's Avatar
    Join Date
    Sep 2003
    Location
    Wales
    Posts
    1,181
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    pergesu - yeah, I will be programming the shopping cart in PHP. I will be programming in PHP 4.2.3, but am not sure exactly how it handles 'interfaces'.

    Tryst

  11. #11
    Texan at Heart Corey Bryant's Avatar
    Join Date
    Sep 2003
    Location
    Castle Rock, CO
    Posts
    2,491
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Tryst, you might want to check out oscommerce & their contributions to the gateway for examples. Stymie is correct, each gateway has its own name for each input. (I am just waiting for the US government to get involved & make it standard like they did with healthcare )


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •