# Top 5 Theme Tweaking Tips for WordPress
Easily Convert Blog Post Keywords Into Money Making Links
Powered by MaxBlogPress  

Top 5 Theme Tweaking Tips for WordPress

by admin on July 25, 2010

Tip 1 – How to Add an Automatically Changing Copyright Year in Your Footer

So many blogs don’t automatically change the copyright date when the  new year changes.  When you view these blogs, you don’t know if the owner has just failed to update the date, or if he has abandoned the blog.  I’ve seen blogs with a copyright date of 2000!

You can have WordPress automatically change the copyright date in your footer by putting the following code snippet where you would like the dynamic date to appear.

Copyright &copy; 200x-<?php echo date(‘Y’); ?> Example.com.

Tip 2 – How to Add an “Edit” Link Next to Each Post

Add this code wherever you have a Post, such as the single php, or index.php files.  This way you can edit your Posts without going into the dashboard.  Only admins will be able to see this edit link.

<?php edit_post_link(‘Edit’, ”); ?>

Tip 3 – How to Disable Search Engine Indexing on a Certain Category

This is an SEO ploy, to avoid duplicate content issues.

To prevent search engines from indexing Posts in a certain category, apply this code snippet to your head tags in header.php.
(Note – Change the category number of 4 to the category you want to prevent search engines from seeing.)

<?php if ( is_category(’4′) || in_category(’4′) ) {
echo ‘<meta name=”robots” content=”noindex”>’;
}

Tip 4 – How to Add a Simple “Tweet This” Link to Each Post

Make it easy for your readers to “tweet” your blog post by adding a “Tweet This” button to each blog post.

This is easy to do by putting the following code somewhere in The Loop in the single.php file:

<a href=”http://twitter.com/home?status=I just read <?php the_permalink(); ?>” title=”Send this page to Twitter!” target=”_blank”>Tweet This!</a>

Tip 5 – How to Style Individual Posts and Comments

The best way to accomplish this is by giving each post a unique identifier by making use of “the_ID” inside the loop:

<div id=”post-<?php the_ID(); ?>”>
<!– Post Content –>
</div>

Related to that, if you want to add a unique identifier to each comment, you could use the following code snippet:

<div id=”comment-<?php comment_ID() ?>”>
<!– Comment Content –>
</div>

Have anything on your mind? Then please add your comment or contact me!

Powered By WP Footer

Leave a Comment

Previous post:

Next post: