Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
<?php
// Using post title as the value, but it's just an example.
add_user_meta( $user_id, $post_id, $post_title );
<?php
// User user email address a value but just an example.
add_post_meta( $post_id, $user_id, $email_address );
<?php
/**
* Using this association will give you the ability to query for information
* both on posts and users and then work with the data accordingly.
*/
add_user_meta( $user_id, $post_id, $post_title );
add_post_meta( $post_id, $user_id, $email_address );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.