FAQ

  • The schedule doesn’t run at defined time.
    Follow this article  and replace WordPress cron with real cron.
  • I haven’t received any emails.
    Did you choose option “Since Last Run”?
    You will get only new orders in this case, so you should create test order to get the email.

Check Helpdesk to see more solutions…


Hooks/filters

  • Each column can be modified by filter before output.
    Hook names depend on type of field  and field name
       for order  – woe_get_order_value_{field}
       for product  – woe_get_order_product_value_{field}
       for coupon  – woe_get_order_coupon_value_{field}
    Use section “Setup fields” to find {field} –  hover the field(see tooltip on the screenshot)  OR switch to “JSON” format

    //Example: we use  usermeta field  to fill First Name
    add_filter('woe_get_order_value_first_name',function( $value,$order ) {
      $user_id = $order->get_user_id();
      return get_user_meta($user_id, 'first_name', true); 
    }
    , 10, 2 );

     

  • It’s possible to skip order using filter woe_order_export_started
    //  export only orders with total > 10
    add_filter( 'woe_order_export_started',  function ( $order_id ) { 
      $order = new WC_Order($order_id);
      return   ($order->get_total()  > 10.00) ? $order_id: false;
    });
    

     

  • There are extra filters to format final text before output
    woe_xls_output_filter, woe_csv_output_filter, woe_xml_output_filter, woe_json_output_filter

    Example: we add namespace "ns2:" to all tags
    add_filter( 'woe_xml_output_filter', function( $xml, $rec  ) { 
      // for <test> 
      $xml = preg_replace( '/(?<=\<)([^\/].*?)(?=\>)/', 'ns2:$1', $xml);
      // for </test>
     $xml = preg_replace( '/(?<=\<\/)(.*?)(?=\>)/', 'ns2:$1', $xml); 
     return $xml; } , 10, 2);

More examples here