Viewing 1 replies (of 1 total)
  • Hi Rahul,

    Thank you for providing the code which you are using in the functions.php file.

    We store the Delivery Date for an order in the ‘Delivery Date label’ meta key (the label which is set in the Appearance tab) in the wp_postmeta table, also we store the UNIX timestamp of the selected date in the ‘_orddd_lite_timestamp’ meta key in the same table and not in the wp_usermeta table.

    So, you can change the provided code to the below code:

    $field_date_label = get_option( ‘orddd_lite_delivery_date_field_label’ );
    $data = get_post_meta( $order_id, $field_date_label, true );

    We have a function ‘orddd_lite_get_order_delivery_date’ in our plugin to obtain Delivery Date information for a particular order. I am attaching an example for your reference:

    <?php
    $order_id = 786; /*sample order ID*/
    $orddd_class = new orddd_lite_common();
    $delivery_date = $orddd_class->orddd_lite_get_order_delivery_date($order_id);
    ?>

    Parameters:
    $order_id – This contains the order id for which delivery date is obtained.

    Please let me know whether the provided information helped you in achieving your requirements.

    Regards,
    Komal Maru.

Viewing 1 replies (of 1 total)
  • The topic ‘Getting Delivery Date blank’ is closed to new replies.