Hi Team,
I have created a custom field for users, which is DATE type. I have tried retrieving that custom field value by -
$recent_working_month = 'recent-working-day-month';
$recent_working_month_value = get_user_meta( $user_id, $recent_working_month, true );
but this code is not working and I'm not getting the Date value. Please guide me how can I get the Date custom field value.
Thanks! but the date in the database is "20 June 2022" and the value I'm getting from above code id "1655683200". I didn't understand. Does it need any conversion?
Types stores custom date field value to database as Unix timestamp. You will have to convert this Unix Timestamp to readable date using PHP date funciton.