• You may have noticed that on quite a few blogs (see Asterisk, Superflous Banter, Dunstan’s Blog) the site owner gets a specially styled comment box when replying to other peoples comments. Sometimes the comment box is a different color, has a different header or border, or just has a distingushing icon. This makes their replies stand out in case someone is just scanning a long list of comments on your blog.
    I have written a simple hack tutorial on how to achieve this effect in WordPress for anyone who is interested. The post is here.

Viewing 14 replies - 1 through 14 (of 14 total)
  • Is there any hope that this feature will some day be included in WP by default or be available as a plugin?

    Thread Starter solano

    (@solano)

    I definitely think the feature should be standard in the installation. They should add different classes of comments — a style hook for trackbacks, a style hook for regular users, a style hook for the admin, a style hook for spam. There really are quite a few possibilities… with little modification you could use my above hack to acheive any of these effects really easily.

    I really like the idea of highlighting the author’s comments, but using e-mail field as a password looks like a bad hack to me.
    I’m still new to WP and have not looked around too much, but there surely is some way to authenticate the author of a comment. If that’s not the case, it should be implemented…

    Thread Starter solano

    (@solano)

    In defense of using the email field as password:
    1.) The email field is used internally by WordPress, email addresses are not displayed on the blog.
    2.) You only use email addresses to contact posters personally.
    3.) All the other fields on the comment form are publicly displayed.
    If you didn’t want to have authentication then it wouldn’t be a problem, just change the one line of code that compares the email address to your password and make it compare the email address to your real email address. This would work fine, but anyone who felt like it could post with your information (if your email is available on your website).
    While it takes a real loser to pose as the author of a blog, it could happen. This could make you look really stupid.
    The one downfall to this hack is that the email field is displayed plain-text, so you wouldn’t want to be posting in a public area.
    Just my thoughts. I think the hack is suitable until the WordPress guys decide to integrate the feature into the system.

    It should be a plugin, not added to the core. If you keep the core lean and mean and full of hooks, then you don’t need to add superfluous things that are dear to only a portion of the users.
    Better to make the application extensible than to weigh it down and create unneeded complexity.

    Thread Starter solano

    (@solano)

    It could easily be an option that is off by default. What is the purpose of having “id = comment-34”? That sounds a bit superflous if you ask me. Theres no way to take advantage of these hooks.

    I use that, I did a few line of code that add the last 8 comments on the top of the menu… hooked thank to that “comment-” except I changer id for a name…. ??

    I think (and I might be deadly wrong, but willing to be enlightened!) that using the same authentication procedure for the comments on a blog that is used for this miniBB based forum would be quite usefull.
    As Solano said it takes a real loser to pose as the author of a blog, but without comment approval it could happen and it makes you look damn stupid. IMHO, allowing anonymous comments shouldn’t be opposed to allow regular visitors or the author itself a minimum anti-spoofing guarantee. Once you can authenticate the author of a comment, you can apply whatever user specific hack or plugin you wish. Of course this would need a user registration feature, something that seems a little offsore for most of the blogs for no known reason to me.
    As said, I might be deadly wrong…

    “What is the purpose of having “id = comment-34″?”
    Like NM says, for those that want extra features, coders can add them.
    I too think that the core code should be kept very lean, with plugins adding the functionality that each blog owner actually does want.
    If 50% love the feature, but 50% do not use it, then it is bloat for that 50%.

    Thread Starter solano

    (@solano)

    Well, my point was that coders *can’t* really add functionality for those hooks. I mean, technically you could create 20+ styles for every single comment-# hook, but what happens when you get 30 comments? What is the relationship between the fourteenth comment on your blog and who created it? Nothing! The hooks are useless. Oh and BTW, Dan Cederholm just made a post about adding author highlighting for MT. A commenter suggested using a password for the email field, as I previously suggested, and Dan responded with “Brilliant”. Seems like the only logical work-around for spoof proofing the current build.

    Thread Starter solano

    (@solano)

    iRET: I never said it was nice ?? A hack is a hack, an ugly modification to the code that makes things work how you want them to. This is the definition of a hack! If it was nice, it would be a plug-in.
    On user registration, I think that this is a very bad idea. I personally instantly leave sites that require me to register for something as simple as posting a comment or reading an article. There must be another way…

    solano: “This is the definition of a hack!” Hehe, true… still…. ;D
    On user registration, I didn’t mean to require registration to post, but to post using a name. Anonymous users (those not registered) can still post whatever they want, but are not allowed to post using a name and thus they can’t impersonate other visitors. Not to say they can’t post using the author’s name!
    I hope this clarifies my point ??

    In case anyone still matters about this, I’ve come to a different approach that both reserves some nicknames for exclusive admin usage and visually differentiates admin comments from those from the visitors/users.
    It is explained in spanish on my website, but it shall be easily understandable by english speakers. If it’s not and there’s enough interest on the subject, I’ll translate it to english.

Viewing 14 replies - 1 through 14 (of 14 total)
  • The topic ‘Differentiating User and Admin Comments’ is closed to new replies.