« | Home | »

WordPress Flickr DHTML Badge Plugin

By Martin English | October 25, 2005

I used to have a Flickr badge running here – It’s now on the homepage. The reason i moved it is because a lot of people (me included) don’t like that it uses Flash. So, when I came across the WordPress Flickr DHTML Badge Plugin, I was a happy puppy…..
It’s meant to be easy to install and configure, and only needs one line added to your sidebar.php to activate!

Unfortunately, there’s something i’m doing wrong….. All I have showing is an empty DIV in the middle of my sidebar….

Debug Notes
The original theme is “Journalised Winter” by Mike little. I have wp_head and wp_footer execuiting; the html generated includes the following code within the <HEAD> tag

@import url(’/wp-content/plugins/tantan/badge.css’);

if (typeof Badge == ‘function’) {
Badge.setSize(48);
Badge.setMargin(1);
Badge.setDelay(3000);
}

and this code is generated in my rightcolumn.php

<div id="tantan-badge" style="width: 150px; height: 150px;"></div>

In the config, I’ve tried both my photstream id and my my username, with and without the flickr userid number (from eightface.com/code/idgettr ).

I even got an API key from flickr.com/services/api and configued it. Still doesn’t work.

The plugin has its own little PEAR subdirectory (in case you don’t have one). Joe suggests removing the PEAR subdirectory but this gave me a bunch of errors along the lines of:

Warning: tantan_phpflickr(HTTP/Request.php): failed to open stream: No such file or directory in /home/martine/public_html/whatsup/wp-content/plugins/tantan/lib.phpFlickr.php on line 71

Update; 26 October
In the end, I got Flickr’s badge code (specifying an HTML badge rather than a Flash badge) to work in less than 2 minutes – its on the lefthand column.

I posted my problems with this over at Joe’s site, and he kindly replied with a fix.
It seems that the reference to /wp-content/plugins/tantan/badge.js
(and .css) is incorrect. In your particular setup, you have wordpress
living on a subdirectory, and this is causing some problems with the
plugin. I think changing the references to
/whatsup/wp-content/plugins/tantan/badge.js (and .css) should fix your
problem.

So if you edit the file tantan_flickrBadge.php and change
“/wp-content/…” on lines 51 and 54 to “/whatsup/wp-content/…”,
then the badge should work.

I’ll make an update to the plugin in the near future to take into
account wordpress installs that don’t live on the root directory.

Hope that helps
Joe

I’ve made the changes (you can see the finished file here).

Topics: Uncategorized | 2 Comments »

Share on FriendFeed Reading: WordPress Flickr DHTML Badge PluginTweet This

2 Responses to “WordPress Flickr DHTML Badge Plugin”

Comments

  • Subscribe to my RSS feed ?



  • Recent….


    • follow me on Twitter
    • www.flickr.com
      This is a Flickr badge showing public photos and videos from martin english (AUS). Make your own badge here.
    • Meta