Hey there,
I'm currently customizing my first WP theme. I chose Thematic as my framework, and I'm creating a Child Theme for it.
I wanted to make a custom function, which would remove some info from each post (author, time of publishing, so on).
I managed to do it, but there's a conflict with my localized Thematic theme.
function childtheme_postfooter() {
global $post;
if (is_single()) { ?>
<div class="entry-utility">
<?php the_time('d. m. Y') ?>
<?php if (('open' == $post-> comment_status) && ('open' == $post->ping_status)) : // Comments and trackbacks open ?>
<?php printf(__('Post a comment or leave a trackback: Trackback URL.', 'thematic'), get_trackback_url()) ?>
<?php elseif (!('open' == $post-> comment_status) && ('open' == $post->ping_status)) : // Only trackbacks open ?>
<?php printf(__('Comments are closed, but you can leave a trackback: Trackback URL.', 'thematic'), get_trackback_url()) ?>
<?php elseif (('open' == $post-> comment_status) && !('open' == $post->ping_status)) : // Only comments open ?>
<?php printf(__('Trackbacks are closed, but you can post a comment.', 'thematic')) ?>
<?php elseif (!('open' == $post-> comment_status) && !('open' == $post->ping_status)) : // Comments and trackbacks closed ?>
<?php _e('Both comments and trackbacks are currently closed.') ?>
<?php endif; ?>
<?php edit_post_link(__('Edit', 'thematic'), "\n\t\t\t\t\t<span class=\"edit-link\">", "</span>"); ?>
</div><!-- .entry-utility -->
<?php } else { ?>
<?php if ( $post->post_type == 'post' ) { // Hide entry utility on searches ?>
<div class="entry-utility">
<span class="comments-link"><?php comments_popup_link(__('Leave a comment', 'thematic'), __('1 Comment', 'thematic'), __('% Comments', 'thematic')) ?></span>
<?php edit_post_link(__('Edit', 'thematic'), "\t\t\t\t\t<span class=\"meta-sep\">|</span>\n<span class=\"edit-link\">", "</span>\t\t\t\t\t"); ?>
</div><!-- .entry-utility -->
<?php } ?>
<?php }
}
add_filter ('thematic_postfooter', 'childtheme_postfooter');
So for example, the function overrides my original, mother tongue version of the following notice "Both comments and trackbacks are currently closed".