Page 7 of 7 FirstFirst ... 567
Results 61 to 64 of 64
  1. #61
    Join Date
    Jul 2008
    Posts
    360
    Plugin Contributions
    0

    Default Re: Create a new module for International Checkout payment module

    Quote Originally Posted by DrByte View Post
    get_products() will return an array ... which you can't display by merely using echo(). You would need to echo print_r($products, TRUE) if you wanted to see the array contents that way
    ok now I am getting somewhere ... my output is ...

    Payment module name: ic
    Admin title for the module International Checkout Payments
    Admin description for the module International Checkout Payments
    True, the number 1 means is enabled

    Products Image[0] path:images/HP-E6930p.jpg
    Products Image[0] Width: 50
    Products Image[0] Height: 40
    Products Quantity[0] :4
    Products price[0] path:$2,320.00
    Products price[0] each path:$580.00
    Products Image[1] path:images/HP-E6930p.jpg
    Products Image[1] Width: 50
    Products Image[1] Height: 40
    Products Quantity[1] :1
    Products price[1] path:$560.00
    Products price[1] each path:$560.00
    Products in cart:

  2. #62
    Join Date
    Jul 2008
    Posts
    360
    Plugin Contributions
    0

    Default Re: Create a new module for International Checkout payment module

    Quote Originally Posted by icecold View Post
    ok now I am getting somewhere ... my output is ...

    Payment module name: ic
    Admin title for the module International Checkout Payments
    Admin description for the module International Checkout Payments
    True, the number 1 means is enabled

    Products Image[0] path:images/HP-E6930p.jpg
    Products Image[0] Width: 50
    Products Image[0] Height: 40
    Products Quantity[0] :4
    Products price[0] path:$2,320.00
    Products price[0] each path:$580.00
    Products Image[1] path:images/HP-E6930p.jpg
    Products Image[1] Width: 50
    Products Image[1] Height: 40
    Products Quantity[1] :1
    Products price[1] path:$560.00
    Products price[1] each path:$560.00
    Products in cart:
    Recent OUTPUT using the testing server html source code:

    HTML Code:
    Payment module name: ic
    <br>Admin title for the module International Checkout Payments
    <br>Admin description for the module International Checkout Payments
    <br>True, the number 1 means is enabled<br>
    <br>Products Image[0] path:<strong>https://www.store.com/store/images/HP-E6930p.jpg</strong><br>
    Products Image[0] Width: <strong>150</strong><br>
    Products Image[0] Height: <strong>150</strong><br>
    Products Quantity[0]: <strong><input name="cart_quantity[]" value="6" size="4" type="text"></strong><br>
    Products price[0]: <strong>$3,480.00</strong><br>
    Products price[0] each: <strong>$580.00</strong><br>
    Products Image[1] path:<strong>https://www.store.com/store/images/HP-E6930p.jpg</strong><br>
    Products Image[1] Width: <strong>150</strong><br>
    Products Image[1] Height: <strong>150</strong><br>
    Products Quantity[1]: <strong><input name="cart_quantity[]" value="1" size="4" type="text"></strong><br>
    Products price[1]: <strong>$560.00</strong><br>
    Products price[1] each: <strong>$560.00</strong><br>
    <p></p><h1>
    Products Array Loop thru contents</h1><p></p>
    productsImage ... https://www.store.com/store/images/HP-E6930p.jpg <br>
    productsName ... Hewlett Packard HP-E6930p Business Laptop <br>
    quantityField ... <input name="cart_quantity[]" value="6" size="4" type="text"> <br>
    productsPrice ... $3,480.00 <br>
    productsPriceEach ... $580.00 <br>
    id ... 2 <br>
    productsImage ... https://www.store.com/store/images/HP-E6930p.jpg <br>
    productsName ... Hewlett Packard HP-E6920p Business Laptop <br>
    quantityField ... <input name="cart_quantity[]" value="1" size="4" type="text"> <br>
    productsPrice ... $560.00 <br>
    productsPriceEach ... $560.00 <br>
    id ... 1 <br>
    <p>Your session ID is f9b5f16d3f3e5ec0a604b570b5d0c2d8.</p>
    Last edited by icecold; 26 Apr 2010 at 07:59 PM.

  3. #63
    Join Date
    Jul 2008
    Posts
    360
    Plugin Contributions
    0

    Default Re: Create a new module for International Checkout payment module

    so far so good but where the module method has to be called in order to pass the hidden fields to the form?

    In this line inside the module ic I call for a bogus action, but nothing happens from the line of code after //This is not working:

    PHP Code:
    function ic() {
        global 
    $order;

        
    $this->code 'ic';
        if (
    IS_ADMIN_FLAG === true) {
          
    // Payment module title in Admin
          
    $this->title MODULE_PAYMENT_IC_TEXT_ADMIN_TITLE;
        } else {
          
    $this->title MODULE_PAYMENT_IC_TEXT_CATALOG_TITLE;
        }
        
    $this->description MODULE_PAYMENT_IC_TEXT_DESCRIPTION;
        
    $this->sort_order MODULE_PAYMENT_IC_SORT_ORDER;
        
    $this->enabled = ((MODULE_PAYMENT_IC_STATUS == 'True') ? true false);
     
    // This is not working 
     
    $this->form_action_url "https://sandbox.php";
    //works fine    
    if ((int)MODULE_PAYMENT_IC_ORDER_STATUS_ID 0) {
          
    $this->order_status MODULE_PAYMENT_IC_ORDER_STATUS_ID;
        }

        if (
    is_object($order)) $this->update_status();
      } 

  4. #64
    Join Date
    Jul 2008
    Posts
    360
    Plugin Contributions
    0

    Default Re: Create a new module for International Checkout payment module

    Quote Originally Posted by icecold View Post
    so far so good but where the module method has to be called in order to pass the hidden fields to the form?

    In this line inside the module ic I call for a bogus action, but nothing happens from the line of code after //This is not working:

    PHP Code:
    function ic() {
        global 
    $order;

        
    $this->code 'ic';
        if (
    IS_ADMIN_FLAG === true) {
          
    // Payment module title in Admin
          
    $this->title MODULE_PAYMENT_IC_TEXT_ADMIN_TITLE;
        } else {
          
    $this->title MODULE_PAYMENT_IC_TEXT_CATALOG_TITLE;
        }
        
    $this->description MODULE_PAYMENT_IC_TEXT_DESCRIPTION;
        
    $this->sort_order MODULE_PAYMENT_IC_SORT_ORDER;
        
    $this->enabled = ((MODULE_PAYMENT_IC_STATUS == 'True') ? true false);
     
    // Note a full bogus URL doesn't work, no error messages
     
    $this->form_action_url "https://www.store.com/store/sandbox.php";
    //works fine    
    if ((int)MODULE_PAYMENT_IC_ORDER_STATUS_ID 0) {
          
    $this->order_status MODULE_PAYMENT_IC_ORDER_STATUS_ID;
        }

        if (
    is_object($order)) $this->update_status();
      } 
    I made a typo before but I am not getting form_action_url to work ... as there are no errors ... no nothing ...

 

 
Page 7 of 7 FirstFirst ... 567

Similar Threads

  1. How to create new payment module?
    By Macedonium in forum Built-in Shipping and Payment Modules
    Replies: 2
    Last Post: 15 May 2009, 09:47 PM
  2. Create payment module for cc gateway
    By ccppll in forum Built-in Shipping and Payment Modules
    Replies: 7
    Last Post: 22 Apr 2009, 05:00 PM
  3. How to Create a Transaction ID for Payment Module?
    By Diego Vieira in forum Built-in Shipping and Payment Modules
    Replies: 0
    Last Post: 21 Mar 2009, 04:40 PM
  4. How to create new payment module?
    By mscro in forum Built-in Shipping and Payment Modules
    Replies: 9
    Last Post: 28 Apr 2008, 12:23 AM
  5. How do I create a new payment module?
    By meeven in forum Built-in Shipping and Payment Modules
    Replies: 7
    Last Post: 12 Aug 2007, 01:29 PM

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
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR