So, I have a following form for my wordpress site:
<?php
$current_user = wp_get_current_user();
?>
<div class="rh_contact_form">
<div class="mdl-textfield rhc_phone_number_class">
<?php if ( is_user_logged_in() ) { ?>
<?php echo '<input type="text" id="rhc_phone" name="rhc_phone" placeholder="Phone number" value="' .$current_user -> rh_phone. '"/>' ;?>
<?php }else{ ?>
<input class="mdl-textfield__input" type="text" id="rhc_phone" name="rhc_phone" placeholder="Phone number" value=""/>
<?php } ?>
</div>
<div class="rhc_ask">
<textarea class="mdl-textfield__input" type="text" rows= "3" id="rhc_ask" name="rhc_ask" placeholder="Ask seller"></textarea>
</div>
<input type="submit">Submit</input>
</div>
So, there are two user metakeys: rh_phone
, and rh_ask
How do I update the metavalue for these two?
Thanks!