As the gif is a background image assigned through css to the post title’s <h2>
tag, you’ll have to attack this in two places.
1. Modify your theme’s style.css, changing h2.pen
to h2.pen1
, and adding a new class declaration:
h2.pen2 {
margin-bottom: 1px;
margin-left: 0px;
padding: 6px 2px 2px 24px;
background: url(images/pen2.gif) no-repeat 0px 4px;
}
2. At the start of The Loop in your theme’s template(s), you’ll want to insert this bit of PHP:
<?php
if('private' == $post->post_status) {
$pen = 'pen2';
} else {
$pen = 'pen1';
} ?>
You also need to alter the opening <h2>
tag, so it’s:
<h2 class="<?php echo $pen; ?>" id="post-<?php the_ID(); ?>">
Note on forum posting: please don’t post the same question multiple times. If you’re new to WordPress and the forums, this Codex page is recommended:
https://codex.www.ads-software.com/Using_the_Support_Forums