[wp-hackers] Show unapproved comments on custom post type for some users

Ryan Bilesky rbilesky at gmail.com
Fri Jan 7 15:06:49 UTC 2011


Ok also I know that a theme can specify a callback function to format
comment output, is there a way to do this via a plugin, these comments that
are being displayed only to some users I want to apply custom styling to
them if possible to make them stand out.

On Jan 7, 2011 2:20 AM, "Peter Westwood" <peter.westwood at ftwr.co.uk> wrote:
>
> On 6 Jan 2011, at 22:10, Ryan Bilesky wrote:
>
>> Ok so a little background here, I am working on a plugin that registers a
>> custom post type. II am using comments with the custom post type and
>> specifically I am using the "unapproved" designation for comments that I
>> want to show to a select group of users, say those with the edit_posts
>> capability. Now I want to do this in a way that works with any theme. I
>> have found a way, modifying the comments.php template, to show unapproved
>> comments. What I am looking for is a way to use custom coding for the
>> active themes comments.php for my custom post type within my plugin, so
use
>> is as simple and installing and activating the plugin. Is there a way I
can
>> do this?
>
> I wouldn't use the unapproved designation for these comments but rather
use a separate extra status to mark them out.
>
> I would then hook into the comment queries and return the comments when
appropriate to the theme
>
> Cheers
> --
> Peter Westwood
> http://blog.ftwr.co.uk | http://westi.wordpress.com
> C53C F8FC 8796 8508 88D6 C950 54F4 5DCD A834 01C5
>
> _______________________________________________
> wp-hackers mailing list
> wp-hackers at lists.automattic.com
> http://lists.automattic.com/mailman/listinfo/wp-hackers


More information about the wp-hackers mailing list