Results 1 to 3 of 3
  1. #1
    Join Date
    May 2009
    Posts
    2
    Plugin Contributions
    0

    Default Payment module porting from oscommerce problem

    Hello!
    I'm having a problem with ported oscommerce module. I made some changes and everything was fine, but then an error occured.

    Here's code:

    Code:
    // if there is nothing in the customers cart, redirect them to the shopping cart page
      if ($cart->count_contents() < 1) {
        zen_redirect(zen_href_link(FILENAME_SHOPPING_CART));
      }
    After last step in checkout I get blank page and debug log says:

    Code:
    [11-May-2009 14:56:06] PHP Fatal error:  Call to a member function count_contents() on a non-object in C:\wamp\www\mariola\zencart\ext\modules\payment\platnosci\checkout_platnosci.php on line 30
    I am newbie with this stuff so maybe someone know how to resolve this problem.

    Function count_contents() is method of shoppingCart class.

  2. #2
    Join Date
    Jan 2004
    Posts
    66,443
    Plugin Contributions
    279

    Default Re: Payment module porting from oscommerce problem

    $cart should be $_SESSION['cart'] in Zen Cart v1.x
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  3. #3
    Join Date
    May 2009
    Posts
    2
    Plugin Contributions
    0

    Default Re: Payment module porting from oscommerce problem

    Thanks a lot, it works!

 

 

Similar Threads

  1. Porting module from osCommerce to Zen Cart
    By local1970 in forum Addon Payment Modules
    Replies: 4
    Last Post: 4 Apr 2011, 08:23 AM
  2. Porting osCommerce iTransact CC Module
    By wulfmaer in forum Addon Payment Modules
    Replies: 12
    Last Post: 25 May 2010, 11:38 PM
  3. porting a payment module from osC
    By Michi71 in forum Addon Payment Modules
    Replies: 1
    Last Post: 14 Feb 2008, 01:46 AM

Posting Permissions

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