How to Create a Dynamic Footer Carousel Graywolf's SEO Blog |
How to Create a Dynamic Footer Carousel Posted: 18 Feb 2011 07:44 AM PST In my piece on How to Build an Effective Footer, one of the tips I mentioned was making your footer more dynamic by including links to posts that are currently popular on your website. It’s something I do on the bottom of this website. I’ve gotten a few emails asking how, so I figured I’d turn it into a tutorial. One method you could use is selecting the most recent posts from a specific category. I covered how to do that in my How to Add a Carousel Post. However, for my footer, I wanted something with a date aspect to it. What I really wanted was to display the most popular posts from the current day. Since I’m pushing out 4-6 archived posts on twitter per day, this does a really good job of keeping the footer from looking active. Additionally if I have a really popular post that links to another post, it’s pretty likely to populate the footer as well. Most of the heavy lifting is done via the WordPress popular posts plugin, which does all the calculating for you. It can spit out the code for you via widget, but chances are it won’t fit nicely into your theme. You’re going to need to do a bit of customization–thankfully the plugin has that functionality built in. You don’t have to use Thesis to make this work, but it is a lot easier (see Thesis Review). We need to open up our custom functions file and, if you don’t already have a footer function, you’ll need to add one like this:
I’ll step you through what each of the parameters means range=daily – Use the daily time frame. You can also use weekly or monthly. Once that’s all done make sure you are calling the footer. At this point you might see a bunch of empty boxes. That means you aren’t using the “featured image” field for your posts. So you’ll need to edit some of your older posts and put that in. If you’re images are stacked one on top of each other, you’ll need to float them by adding something like this t your CSS file.
The code can also be adapted and expanded; for example my Most Popular Posts page uses a variation of the code with a longer time frame and larger number of posts. The Bad NewsThere are some downsides to implementing this code. As some hosting companies have explained to me, this is a very resource intensive plugin. If you are on shared hosting you may go over your CPU limits if you have a busy website or include a lot of images. Secondly, the more images you use, the slower you make your pages, and page speed plays a small role in rankings (see How to Speed Up WordPress). Lastly I haven’t been able to get the plugin to generate rectangular shaped images. I can make them wider but all it does is stretch the square image out. If the featured image is a rectangle it won’t just use the rectangle. Related posts:
Advertisers:
This post originally came from Michael Gray who is an SEO Consultant. Be sure not to miss the Thesis Wordpress Theme review. |
You are subscribed to email updates from Graywolf's SEO Blog To stop receiving these emails, you may unsubscribe now. | Email delivery powered by Google |
Google Inc., 20 West Kinzie, Chicago IL USA 60610 |
Niciun comentariu:
Trimiteți un comentariu