- 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.zip
file or thefilosofo-comments-preview.tar.gz
file 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.