Vandelay Design

9 WordPress Hacks to Encourage User Interactivity

Published August 24th, 2009 in WordPress

All bloggers would like to get more interaction and participation from their readers and visitors. In this post we’ll look at nine different things you can do to your WordPress theme to add the possibility of some type of interaction. Some involves comments, social media, and other ways of getting readers involved.

1. Show Most Recent Comments

One of the most important ways that blogs can encourage readers to get involved is through the comments. There are a number of different strategies for increasing comments and participation from readers, and many of them involve placing extra emphasis on the comments. By displaying the most recent comments (in the sidebar for example) you may be able to encourage more comments because visitors will see that you value their participation.

To display a list of the most recent comments, use the following code in your theme:

comments
LEFT OUTER JOIN $wpdb->posts ON ($wpdb->comments.comment_post_ID =
$wpdb->posts.ID)
WHERE comment_approved = '1' AND comment_type = '' AND
post_password = ''
ORDER BY comment_date_gmt DESC
LIMIT 10";
$comments = $wpdb->get_results($sql);
$output = $pre_HTML;
$output .= "
\n
<ul>";
foreach ($comments as $comment) {
$output .= "
\n
    <li>".strip_tags($comment-&gt;comment_author)
."
:" . "<a href="\">ID) .
"
#comment-" . $comment-&gt;comment_ID . "\" title=\"on " .
$comment-&gt;post_title . "\"&gt;" . strip_tags($comment-&gt;com_excerpt)
."</a></li>
"
;
}
$output .= "\n</ul>
"
;
$output .= $post_HTML;
echo $output;?&gt;

Source: WP Hacks

2. Allow Visitors to Email Posts to Their Friends

If your readers enjoy and appreciate the posts on your blog they may be interested in emailing them to their friends. On most news websites you’ll see a link that says “email to a friend,” but it’s not as common on blogs. Adding this functionality into your theme is not as difficult as you might think.

To add an “email this” link, use the following code in your single.php file:

<a href="mailto:?subject=<?php the_title();
?>&amp;body=<?php the_permalink() ?>" title="Send this
article to a friend!">Email this</a>

Source: WP Recipes

3. Add a “Share on Facebook” Link

While social media and social networking are commonly integrated with blogging, it’s more common to see a Digg or Tweetmeme button than one that will allow readers to share the link via Facebook. Since Facebook is such an incredibly popular site, it may provide additional exposure for your blog and provide more opportunities for your readers to interact with your content.

To add a “share on Facebook” link, use the following code:

<a href="http://www.facebook.com/sharer.php?u=&lt;?php the_permalink();?&gt;&amp;t=&lt;?php the_title(); ?&gt;" target="blank">Share on Facebook</a>

Source: WP Recipes

4. Add Custom Bookmark Links

Many blogs receive tremendous exposure from social media sites, and encouraging your readers to interact by voting or bookmarking can make a big difference in terms of traffic levels. There are plugins and widgets available for this purpose, as well as buttons and badges from the social media sites, but if you’d like more control over the look or if you would just like to do it yourself it is possible.

Bookmark with Delicious:

<a title="Bookmark this post at Delicious" rel="nofollow" href="http://delicious.com/post?url=&lt;?php the_permalink(); ?&gt;&amp;title=&lt;?php echo urlencode(get_the_title($id)); ?&gt;">Bookmark at Delicious</a>

Digg:

<a title="Submit this post to Digg" rel="nofollow" href="http://digg.com/submit?phase=2&amp;url=&lt;?php the_permalink(); ?&gt;">Digg this!</a>

Twitter:

<a rel="nofollow" href="http://twitter.com/home?status=<?php echo urlencode("Currently reading: "); ?><?php the_permalink(); ?>" title="Share this article with your Twitter followers">Tweet this!</a>

StumbleUpon:

<a title="Share this post at StumbleUpon" rel="nofollow" href="http://www.stumbleupon.com/submit?url=&lt;?php the_permalink(); ?&gt;&amp;title=&lt;?php echo urlencode(get_the_title($id)); ?&gt;">Stumble this!</a>

Source: Perishable Press

5. Rearrange the Comments to Show Most Recent Comments First

Having a blog that receives a lot of comments from readers can in some ways discourage others from participating. Some readers will not take the time to leave a comment if they feel like theirs will be buried below 100 other comments. One trick to reward those who are going to take the time to comment is to list the comments with the most recent on top, rather than the oldest one being on top.

Find the following code in your comments.php file (please note that not all themes use the same coding for the comments.php file):

foreach ($comments as $comment)

and before it add:

$comments = array_reverse($comments);

Source: WordPress Forums

6. Add a User-Submitted News Section

User-submitted news or community news sections can be a great way for visitors to get involved at your site. With a news section you will be able to display links to relevant posts at other blogs, and your readers will be able to submit posts that they have found to be helpful, or get some extra promotion by submitting links to their own posts.

I included a news section when I launched DesignM.ag last year and since day one it has drawn significant interest from readers.

The process of adding a news section is more involved than just copying and pasting some code, so I will not be providing code for this one, but Tripwire Magazine published a post a few months ago that will lead you through the process. See How to: WordPress 2.7+ User Link Feed Submit Form and Widget.

7. Add Translation Links

As a blogger, you may be surprised to see how many of your visitors and subscribers come from various countries. While these people may be able to read and understand your posts, there may be some times when they have difficulty or where they would like to share the post with someone who may not be able to read it. In these case, translation can come in handy.

Inserting the code shown below will allow your visitors to easily use Google’s translation services:

<ul id="translations">
    <li><a rel="nofollow" href="http://translate.google.com/translate?u=&lt;?php echo urlencode('http://'.$_SERVER['HTTP_HOST'].$_SERVER['REQUEST_URI']); ?&gt;&amp;langpair=en%7Cde">Translate this page to Deutsch</a></li>
    <li><a rel="nofollow" href="http://translate.google.com/translate?u=&lt;?php echo urlencode('http://'.$_SERVER['HTTP_HOST'].$_SERVER['REQUEST_URI']); ?&gt;&amp;langpair=en%7Ces">Translate this page to Espanol</a></li>
    <li><a rel="nofollow" href="http://translate.google.com/translate?u=&lt;?php echo urlencode('http://'.$_SERVER['HTTP_HOST'].$_SERVER['REQUEST_URI']); ?&gt;&amp;langpair=en%7Cfr">Translate this page to Francais</a></li>
    <li><a rel="nofollow" href="http://translate.google.com/translate?u=&lt;?php echo urlencode('http://'.$_SERVER['HTTP_HOST'].$_SERVER['REQUEST_URI']); ?&gt;&amp;langpair=en%7Cit">Translate this page to Italiano</a></li>
    <li><a rel="nofollow" href="http://translate.google.com/translate?u=&lt;?php echo urlencode('http://'.$_SERVER['HTTP_HOST'].$_SERVER['REQUEST_URI']); ?&gt;&amp;langpair=en%7Cpt">Translate this page to Portugues</a></li>
    <li><a rel="nofollow" href="http://translate.google.com/translate?u=&lt;?php echo urlencode('http://'.$_SERVER['HTTP_HOST'].$_SERVER['REQUEST_URI']); ?&gt;&amp;langpair=en%7Car">Translate this page to Arabic</a></li>
    <li><a rel="nofollow" href="http://translate.google.com/translate?u=&lt;?php echo urlencode('http://'.$_SERVER['HTTP_HOST'].$_SERVER['REQUEST_URI']); ?&gt;&amp;langpair=en%7Cja">Translate this page to Japanese</a></li>
    <li><a rel="nofollow" href="http://translate.google.com/translate?u=&lt;?php echo urlencode('http://'.$_SERVER['HTTP_HOST'].$_SERVER['REQUEST_URI']); ?&gt;&amp;langpair=en%7Cko">Translate this page to Korean</a></li>
</ul>

Source: Perishable Press

8. Google Custom Search

One of the best ways for visitors to find what they are looking for is to use a site-wide search. Unfortunately, the default WordPress search isn’t much help in most cases. However, you can easily add custom search powered by Google to your blog (plus you can monetize the search through AdSense).

In order to get your own custom search from Google, you will need to sign up with them and they will provide the code. Pro Blog Design has a tutorial that takes you through all of the steps that are involved. See Make a Google Custom Search for Your Blog, and Make Money.

9. Display Facebook Status on Your Blog

Many blogs display most recent tweets, but it’s also possible to share your Facebook status on your blog. There are a few steps involved in doing this with WordPress, and Hongkiat has a tutorial that will lead you through the process. See How to Display Facebook Statuses on WordPress Blog.

For more WordPress-related posts please see:

91 Responses to “9 WordPress Hacks to Encourage User Interactivity”

Angie Bowen August 24th, 2009

Great article! I had never really thought about adding translation links before but it’s a great idea. I would also add having some way for the commenter to subscribe to the comments so they can follow the discussion.

Vandelay Website Design August 25th, 2009

Good point Angie. I use the subscribe to comments plugin and find it to be one of the most useful plugins.

Ryan August 25th, 2009

Great tips especially reversing the comments will have to do that on my site.

The subscribe to comments plugin is definitely a must and can keep the conversation flowing.

Michael Murdock August 25th, 2009

Nice sharing.

Michael Oeser August 25th, 2009

At least the email and the twitter link doesn´t work at all :-(

Jeff Starr August 25th, 2009

Awesome collection of hacks. Bookmarked and (Re)Tweeted. Thank you for including some Perishable Press snippets! :)

BizBamboo August 25th, 2009

Hi, I think its informative and useful for me. I have noted some points from
this article, good article for me. Thank you very much for sharing. Regards,
- Bizbamboo

hiddenson August 25th, 2009

Nice list of tips.

I would like to add gravatars and perhaps single sign-on through OpenID or others. Let’s face it: an overdose of profiles does not foster account creation, but we help users to subscribe seamlessly, we may have a winner.

Dave Sparks August 25th, 2009

Nice article, a lot of the things like emailing and sharing links can be done quickly and easily using plugins such as addtoany (http://wordpress.org/extend/plugins/add-to-any/) and sexy bookmarks (http://www.sexybookmarks.net) to name two.

Vandelay Website Design August 25th, 2009

Michael Oeser,
You’re right. I tested everything before publishing but I must have somehow changed the code because they are not working. I fixed them both and re-tested (the code from the sources work in both cases). Thanks for pointing it out.

patricia de miranda August 25th, 2009

so nice all this hints… i´m just sad because isn´t for to blogspot ; ((

Brian August 25th, 2009

I don’t think the Facebook status trick works since FB implemented their new layout a few months ago.

I couldn’t get it to work and searched around the web and everyone else is having the problem as well.

If anyone knows how to post FB status now please post a link.

opal earrings August 25th, 2009

Cool The google translation could be very Helpful,
and I was looking for some Comments plugins so thanks for sharing the hack

Matt August 25th, 2009

Great hacks! Thanks for sharing.

Alexander Bickov August 25th, 2009

Thanks! Useful post for my fresh blog

Hugo Moreno August 25th, 2009

Excellent thanks for the tips!!

Nick Gernert August 25th, 2009

Not sure I agree with #5 here. The point of comments is that there is a progression in conversation beyond the author’s post. By reversing comment order you are encouraging ignorance to this progression.

If your blog gets 100s of comments, people *should* think twice before just posting another comment. If 10 other people have already made the point, why encourage yet another person to do the same? The emphasis should be on comment quality, not quantity.

Methods such as highlighting author responses, allowing users to rate comments and threading can all be methods to surface and organize the best of comments without just rewarding the guy who chimed in most recently.

Scott Langendyk August 25th, 2009

Is it just me or is it a little ironic that the comments on this blog do not follow the guideline in this post.

Kim H August 25th, 2009

Very nice post; I may end up using these on my blog – I get some traffic but not as much interaction as I’d like.

Tanay | TJDzine August 25th, 2009

Great Post. I might use the translation links hack on my blog. Maybe it will help increase readership? Will let you know how it goes.

Vandelay Website Design August 25th, 2009

Scott,
It’s not a “guideline”, just an option.

Nick,
I’m not saying it’s something that I recommend, just something that you can consider if you’re looking to try and get more comments. I agree with you that the progression and chronological order has some significance, and that is why I choose not to display them in reverse order. Some blog’s use the reverse order and it works for them (example, Web Designer Wall).

Tony August 25th, 2009

I’ve not had good luck with translations in WordPress (tried several plug-ins, Google translations included). It bumps up my visitors, which is nice, but when I’d get comments from foreign language readers they’d always be complaints. It seems to be upsetting to people to get a result for their search that is barely readable. German translations seemed to be the most complained about.

I just wound up removing it entirely.

The Therapist August 25th, 2009

Great tools that allow us to interact with our visitors! I need to implement a facebook status on my blog, in order to maintain all my friends updated. Thanks!

Brad August 25th, 2009

Good list of suggestions, thank you.

Vandelay Website Design August 26th, 2009

Tony,
That’s interesting feedback. I can see where that would be more harmful than positive if the translation is not very good. Thanks for sharing from your experience.

Dani McDaniel August 26th, 2009

Great post.. thanks for including the email this code! I like to use the eco-safe plugin (http://eco-safe.com/green/wordpress) but your snippet is perfect for those clients that want a less obvious link ;)

Barbara Ling, Virtual Coach August 26th, 2009

Great collection of hacks! I also like using a threaded comment reply resource so commentators can follow conversations.

Nick, just Nick August 26th, 2009

Very useful tips. I use a Share This plug-in which works pretty nicely and allows the reader to send a link to every social bookmarking site that I know of.

Another tip that isn’t really a hack is to reply to the comments your readers leave. Create a sense of involvement – even if it is an argument!

mar18 August 26th, 2009

i am a new blogger- not familiar with codes or html yet. how do i learn?

Trent Walton August 26th, 2009

I’m not sure it’s a hack, but separating trackbacks from comments (as you have done here) is always a smart move.

Prentiss Riddle August 26th, 2009

Great list, but may I suggest caution about sending your readers to translation services. Despite great strides, the quality of translation is extremely uneven and if a proper understanding of your content is important you shouldn’t rely on it.

A specific example: a site that I work on had prominent text on the front page that said in English, “___ is a program unlike any other.” As translated by Google into Portuguese, the message became “____ is a program *like* any other.”

If you’re willing to say any kind of nonsense including the exact opposite of what you mean, go for it. I might offer translation links on a personal or recreational site but never on a serious business or organizational site.

Trendy Wordpress Themes August 26th, 2009

These are all good, thanks.

Vandelay Website Design August 26th, 2009

Thanks for the advice Prentiss. Another reader had a similar experience with poor translation.

Vandelay Website Design August 26th, 2009

Hi Barbara,
Threaded comments are definitely an option. I’m personally not a big fan of them because I’ve seen them abused on many other sites. People wind up “replying” to the first comment rather than leaving their comment at the end, even though it has nothing to do with the comment they are replying to. I think it’s effective if people use it as intended, but otherwise it can make the comments more of a mess and difficult to follow.

Pure and Simple Web Design August 26th, 2009

Great post on user interactivity – I’ll be looking at adding the translation links to my web design blog over the next couple of days.

I found this – http://www.addthis.com/ – to be handy for social bookmarking and have it on my blog and website. Choose a couple of options, copy code, paste in desired location on your website or blog, and bingo!

Delicious, Buzz, Digg and on to more business-oriented social bookmarking websites such as LinkedIn are included on a drop-down.

The only draw back I can think of is that (for me) it’s not as easily recognisable as the Delicious logo/ Stumble logo, but I’m running with it at present.
Darren.

Vandelay Website Design August 26th, 2009

Hi Darren,
My experience with widgets and plugins like that was that no one really used them. Hopefully it will work better for you.

pavankumar August 27th, 2009

I never thought i would find a way to transition, thanks to you. Your article is really interesting.

Sid August 28th, 2009

Bookmarked it thanks for the info

dolar August 29th, 2009

These are all good, thanks

Shawn Hooghkirk August 29th, 2009

Thank you for the great article!

I have been looking for translation hacks for some time now!

Clare August 31st, 2009

Some useful tips here. I have translation switch on on one of my sites and you’d be surprised how much of my traffic now comes from places like Russia!

Only problem comes when they try to leave a comment and I have no idea what language its in so I can’t translate it back to English!

Tampa Web Optimization August 31st, 2009

Gotta love the hacks!

Güncel September 2nd, 2009

Great hacks!
Thanks for sharing.

Free Wii Points September 2nd, 2009

Thanks for those snippets of code! I will modify my blog right now!

Yonglin September 2nd, 2009

Nice List! Going to place some into my site! Thanks!

arun kumar September 2nd, 2009

hey nice article … thanks for sharing ??
can say a good collection !!

We Are Web September 4th, 2009

Great list of hacks here, don’t forget the RSS blog link too – I know this isn’t a hack as such but it’s important to add in in terms of allowing content to be distributed.

Website Design September 4th, 2009

thanks for sharing your knowledge with us :)

David September 10th, 2009

I’ve been looking for a way to include user link feeds. Great article and tips

Tammy September 10th, 2009

An easy to use option is the ’send to a friend’ I actually get more responses this way- from a friend of a friend and they immediatlely become a ‘fan’ of my facebook page ( which is on the site) as they want to impress their friends more than they particularly care about my content.
Sad…but true.

Web Design Australia September 11th, 2009

Thanks for sharing these things. But I think it’s more appropriate to regard them as tips and not as hacks.

Kirsty Wilson October 13th, 2009

Thanks for the useful list of “tips”. However, I am curious why your Comments aren’t following your own guidlines by listing the most recent comment first?

Vandelay Website Design October 14th, 2009

Hi Kristy,
As I have said to other commenters, the list of hacks is not a suggestion of things that you should be using, it’s simply a list of things that are possibilities should you be interested in using them. Personally, I prefer to keep comments int the default order, but some other sites have effectively used reverse order, so it is something worth knowing in case a client wants it that way.

Web Design Australia November 28th, 2009

Thank you for these great tips. I love the bookmarking suggestions. It is something I have yet to implement on some of my WordPress sites and I think it can only help to draw more free traffic.

WPExplorer December 25th, 2009

This is a great list. What about having a list of Top Commentators with dofollow links?

Dell Inspiron B130 January 27th, 2010

but there are not so many functions to use in wordpress.

mike February 2nd, 2010

I love all the comments here. Keep it up.

Trackbacks

Leave a Reply