• Resolved zr2121

    (@zr2121)


    Hi there,

    My woocommerce checkout page has a wp_dropdown_users() where the customer can select who they want their recipient to be.

    From that result I am looking up the user meta using get_user_meta() to retrieve all the shipping details.

    I want to use that to fill the shipping checkout fields which I have previously accessed using woocommerce_checkout_fields but I cannot anywhere find a way to set those fields (there only seems to be instructions on how to unset or change the placeholder)

    Please can someone help me with how to set those fields using the retrieved data.

    I would like to do this in functions.php which should be possible but is not clear how.

    If not I can try another solution but this would (/should) be the most straightforward I feel.

    Many thanks

Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)

The topic ‘using get_user_meta to populate shipping fields’ is closed to new replies.