admin_order_totals

The WooCommerce Sisow Mastercard admin order totals function.

Description

admin_order_totals( $order_id ); 

Parameters (1)

0. $order_id
The order id.

Usage

  1. if ( !function_exists( 'admin_order_totals' ) ) { 
  2. require_once ABSPATH . PLUGINDIR . 'woocommerce-sisow-mastercard/sisow/base.php'; 
  3.  
  4. // The order id. 
  5. $order_id = null; 
  6.  
  7. // NOTICE! Understand what this does before running. 
  8. $result = admin_order_totals($order_id); 
  9.  

Defined (1)

The function is defined in the following location(s).

/sisow/base.php  
  1. function admin_order_totals($order_id) { 
  2. global $woocommerce; 
  3.  
  4. $label = get_post_meta($order_id, '_processing_fee_label', true); 
  5. $processing_fee = get_post_meta($order_id, '_processing_fee', true); 
  6.  
  7. if (!$processing_fee) 
  8. return; 
  9. ?> 
  10. <div class="clear"></div> 
  11. </div> 
  12. <div class="totals_group"> 
  13. <h4><?php echo $label; ?></h4> 
  14. <ul class="totals"> 
  15.  
  16. <li class="left"> 
  17. <label><?php _e('Amount:', 'woocommerce'); ?></label> 
  18. <input type="text" id="_processing_fee" name="_processing_fee" value="<?php echo $processing_fee; ?>" class="first" /> 
  19. </li> 
  20. </ul> 
  21. <?php