• Resolved RenderWarrior

    (@web4people)


    Hello,

    I created a custom snippet that gets the order details and write them on a different database (attached to a custom backend, not related to WordPress).

    I can get all the WooCommerce fields without problems. But how can I get the values from the custom fields generated by your free plugin?

    I noticed the field is saved in the wp_postmeta table, but I would like to avoid to write a custom code for getting it from there if I can access it directly from the thank you page.

    I don’t need to show that value on the page, I just need to get the value. If I print_r the order, I see it within the array, but I’m relatively new to the Woocommerce world, so I don’t know how accessing it… is it inside a specific array? Or do I need a specific object to query?

    Thanks

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter RenderWarrior

    (@web4people)

    ok, I got it… I used $order->get_meta(‘myfield’)

    Just a question: if I would set a custom field like a password, it will be saved to the db in clear. Is it possible to hash it after typing it directly with the plugin?

    Plugin Author ThemeHigh

    (@themehigh)

    Unfortunately, your requirement cannot be achieved using the lite version of our plugin.

    Thank you!

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Accessing custom fields at the thank you page’ is closed to new replies.