VirtueMart

WooCommerce

Others

Docs

Support

Blog

About

Forum

IMPORTANT ANNOUNCEMENT: Plugin development ceased, all plugins made available freely (GPL)

With great sadness we have to announce that we are ceasing development of all our VirtueMart, WooCommerce and Joomla plugins. Effective immediately, all our plugins -- even those that were paid downloads -- are made available for free from our homepage (GPL license still applies), but we cannot and will not provide any support anymore.

It has been a great pleasure to be part of the thriving development communities of VirtueMart as well as WooCommerce. However, during the last year it became painstakingly clear that in addition to a full-time job, a young family and several other time-consuming hobbies at professional level (like being a professional singer) the plugin development and the support that it requires is not sustainable and is taking its toll. It has been an honor, but it is now time to say good bye!

Welcome, Guest
Username: Password: Remember me
  • Page:
  • 1

TOPIC: [SOLVED] Need help to display customer order details

Need help to display customer order details 05 Feb 2018 08:17 #1

  • alexanderbiscajin
  • alexanderbiscajin's Avatar Topic Author
  • Offline
  • Posts: 2
I am trying to display customer order details as i have implemented all the steps mention in the tutorial https://www.wpblog.com/display-woocommerce-customer-order-details/ but still i am not having the actual output.

I have taken order id as same implemented there but not having a exact output that shown.
$order_id
$order_meta = get_post_meta($order_id);

Please Log in or Create an account to join the conversation.

Need help to display customer order details 17 Feb 2018 13:01 #2

Dear AlexanderBiscajin,
What information do you want to display exactly? The order number assigned by our plugin should be available as
$order->get_order_number()

There is no need to work with the internals of our plugin, but it's much better to use the API defined by WooCommerce (get_order_number() works with our plugin and it should also work with other order number plugins....)

BTW, if you really need to access the order meta data, you should do something like:
$order_id = $order->get_id();
$order_meta = get_post_meta($order_id, ....)

On the other hand, WooCommerce 3.0 added some more functionality to access internal data through the WC_Order object rather than accessing the (internal) order meta manually. This has to be seen in light of future compatibility: Just because certain things are currently stored as post meta does not mean that they will always be stored as post metas. Providing a nice, clean API at the WC_Order level provides an abstraction between accessing the data and how the data is stored internally.

Best regards,
Reinhold

Please Log in or Create an account to join the conversation.

[SOLVED] Need help to display customer order details 25 Feb 2018 19:57 #3

Problem solved.

Please Log in or Create an account to join the conversation.

  • Page:
  • 1

VM - Shopping cart

 x 

Cart empty

Login Formular