Results 1 to 3 of 3
  1. #1
    Join Date
    Oct 2013
    Location
    MTL
    Posts
    66
    Plugin Contributions
    2

    Default Receipt: Display data from a new table

    Hi, I am using a payment module where it writes certain data to a new table (like processors response approved etc.). I am trying to get that data displayed in the order email. So Here is what I did:
    I edited order.php page and added

    $paymentid_query = "select moneris_orderid, orders_id, response_variables
    from " . TABLE_MONERIS_ORDERIDS . "
    where orders_id = '" . (int)$order_id . "'";

    $paymentid = $db->Execute($payment_query);

    This should give me data for moneris_orderid, orders_id, response_variables

    Further down I added

    $this->paymentid = array('moneris_orderid' => $paymentid->fields['moneris_orderid'],
    'response_variables' => $paymentid->fields['response_variables']);

    Not sure what that does other than assign data to paymentid array

    And went to edit account_history_info_default.php and added to payment_method
    $order->paymentid['moneris_orderid'];

    so that it reads
    <div><?php echo $order->info['payment_method'];
    $order->paymentid['moneris_orderid'];?></div>

    This should display the data help in that variable. However, the end result is the order details of order X where X is the order number eg.7 and below method of payment is nothing but blank.
    What did I miss or did not get correctly?

    Thanks in advance for all teh help you could give me.

  2. #2
    Join Date
    Oct 2013
    Location
    MTL
    Posts
    66
    Plugin Contributions
    2

    Default Re: Receipt: Display data from a new table

    Of course my other option is to write the moneris responss to the orders table and pull it from there but not sure which page to edit and probably which section to edit.. I looked in the checkout_process.php page but could not find the statement resonsible for inserting data in orders table

  3. #3
    Join Date
    Oct 2013
    Location
    MTL
    Posts
    66
    Plugin Contributions
    2

    Default Re: Receipt: Display data from a new table

    Ok, I figured it out. I had forgetten "echo"

 

 

Similar Threads

  1. Replies: 0
    Last Post: 16 Mar 2015, 03:33 PM
  2. how to show data from database table?
    By jibon in forum General Questions
    Replies: 1
    Last Post: 20 Oct 2009, 05:36 PM
  3. Require Search Field to extract more data from a different table
    By callingrohit in forum General Questions
    Replies: 4
    Last Post: 12 Oct 2008, 02:35 PM
  4. How to insert data into a new table
    By MCanes in forum General Questions
    Replies: 3
    Last Post: 19 Feb 2008, 11:19 AM

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