Support » Plugins » [this post] discusses [these people] from among my readers

  • i have a private journal, password access, under 10 readers currently. some of those people are discussed in my journal. there is an element of trust between i and my readers, and those readers of mine who i know in real life understand this: i may possibly discuss you.

    does anyone know of a way to append a tag to each entry, it’d go along with the usual title, date along at the top, that says:

    my entry for today | jan 11, 2006
    people discussed in this entry: jane, john

    and so the reader would know, if they don’t want to read about themselves, they should skip that entry.

    does anyone know if a solution for this already exists? i hope i am posting this to the right subforum. (i had consider various levels of password protection, whatnot, but it just got too confusing, and this is the only workable solution i can think of.)

    all tips would be much appreciated.

Viewing 3 replies - 1 through 3 (of 3 total)
  • You could use custom fields for this. Just enter a new custom field for each person, something like:

    key: discussed
    value: Jane

    You can use the same key multiple times on the same post. Then to display it, you can use a plugin like:

    Plugin: Get Custom Field Values

    Or you could go with a bit of custom code:

    if(get_post_custom_values('discussed')) :
    echo "<p>people discussed in this entry: ";
    foreach(get_post_custom_values('discussed') as $value) :
    if(!$people) $people = $value;
    else $people .= ', ' . $value;
    echo $people . "</p>";

    as many hacks and modifications as i’ve done to my site, i can’t believe i didn’t even know about custom fields. sheesh. =)

    thank you VERY much.

    I’ve been trying to find a way to use the same key multiple times, and I got very hopeful when I read what Kafkaesqui wrote above, but when I tried the solution proposed within the Loop of my setup, it returns ALL values for the given key, not just for an individual post.
    Coffee2code’s solution looked promising also, but it doesn’t offer any means of returning multiple values of the same key for a given post, and s/he appears not to be around anymore (coffee2code hasn’t written in to the WP forums in several months, according to their profile).
    Does anyone have a solution to this problem? I’d be obliged to hear from you!

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘[this post] discusses [these people] from among my readers’ is closed to new replies.