- How do I install the Filosofo Comments Preview plugin?
- How do I customize the markup for a previewed comment in my comments template?
-
How do I install the Filosofo Comments Preview plugin?
You must be using WordPress version 2.0 or newer.
- Download either the
filosofo-comments-preview.zipfile or thefilosofo-comments-preview.tar.gzfile here. Extract the files. - Upload the
filosofo-comments-preview.php
file into your plugins folder (in
http://www.%your_blog_address%/wp-content/plugins/) and activate it in your control panel. - You can set the preview background color under Options > Comments Preview.
- Download either the
-
How do I customize the markup for a previewed comment in my comments template?
To customize the preview markup in your comments template (usually
/wp-content/themes/[your theme]/comments.php
), check whether either of the following returns true:
comment_is_preview()orapply_filters('comment_is_preview','')For example,
<? if ( apply_filters('comment_is_preview','') ) { echo 'class="previewed-comment"'; } ?>
would print
class="previewed-comment", for easy preview-specific styling.
2 Comments
Am getting the following message when I preview the comment before posting:
Warning: strtotime() [function.strtotime]: Called with an empty time parameter. in /wp-content/plugins/filosofo-comments-preview/filosofo-comments-preview.php on line 175.
Do you know what is causing this?
Oops. Looks like you’ve caught a bug. I’ll address it when I have a chance.