Docs: Add backtick escaping around a variable name in the DocBlock for `update_post_meta()`.

Also adds a note to the description explaining that it can be used in place of `add_post_meta()`.

See #42505.


git-svn-id: https://develop.svn.wordpress.org/trunk@44334 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Drew Jaynes 2018-12-19 16:38:51 +00:00
parent 931777debb
commit 367a6cba81
1 changed files with 3 additions and 1 deletions

View File

@ -2027,11 +2027,13 @@ function get_post_meta( $post_id, $key = '', $single = false ) {
/**
* Updates a post meta field based on the given post ID.
*
* Use the $prev_value parameter to differentiate between meta fields with the
* Use the `$prev_value` parameter to differentiate between meta fields with the
* same key and post ID.
*
* If the meta field for the post does not exist, it will be added and its ID returned.
*
* Can be used in place of add_post_meta().
*
* @since 1.5.0
*
* @param int $post_id Post ID.