Dynamic flickr Badge Script

Dynamic flickr Badge Script

1 Star2 Stars3 Stars4 Stars5 Stars (No Ratings Yet)
Loading ... Loading ...
389 views

A work colleague who runs Tobago Retreats asked me to create a gallery badge that automatically shows her latest flickr photos in her gallery and I started another flickr badge from scratch.

All you have to provide is a link to the flickr stream or the tagged images in your stream as a text link with a DIV with the class “flickrbadge” around it.

The script is a single include and loads the style sheet and the YUI help files on demand when they are needed. Visitors can see your photos on the page and click the thumbnails to see the larger preview. You can style the badge any way you like by changing the supplied CSS file.

The script is licensed Creative Commons attribution and is free for use.

If there is interest in a step by step explanation how it works, retrieves the YUI files and the flickr data, I can write something up, but for the moment I’ll be happy about feedback on the script as it is.

It does not work in Opera at the moment and I have a bug request with them running.

Check out the script and download it on its homepage: dynamic JavaScript flickr badge v2

Image hosted on flickr.

Here you can download a script to add a flickr badge like the following to any HTML document or blog with some HTML and a JavaScript include. The following badge is added to the document using this code:

You only need to insert the SCRIPT once, and the best option is to add it to the end of the document, just before the closing BODY tag.

To add a badge all you need to do is add the link inside a DIV with the class flickrbadge and the script does the rest for you. You can use as many badges as you want in the same document. You can also only show pictures of your photo stream tagged with a certain tag, for example tshirtaday:

How to get the right URL

This should be much easier, but there is a small confusion in the flickr API we need to work around. The team is aware of this and we might not have to do that soon (I will update this page if it is fixed).Fixed on 11/09/07 – all hail Cal Henderson!

If your flickr page URL does not feature a user name but the ID (the one with @ inside it), you have no problem. For example the flickr stream of my friend Laura is: http://www.flickr.com/photos/28806816@N00 and that can be used immediately:

Demo: http://icant.co.uk/sandbox/flickrbadgev2/

Download:http://icant.co.uk/sandbox/flickrbadgev2/flickrbadgev2.zip

Source: http://icant.co.uk/sandbox/flickrbadgev2/

http://www.ajaxupdates.com/wp-content/plugins/sociofluid/images/stumbleupon_32.png http://www.ajaxupdates.com/wp-content/plugins/sociofluid/images/delicious_32.png http://www.ajaxupdates.com/wp-content/plugins/sociofluid/images/blinklist_32.png http://www.ajaxupdates.com/wp-content/plugins/sociofluid/images/furl_32.png http://www.ajaxupdates.com/wp-content/plugins/sociofluid/images/technorati_32.png http://www.ajaxupdates.com/wp-content/plugins/sociofluid/images/magnolia_32.png http://www.ajaxupdates.com/wp-content/plugins/sociofluid/images/google_32.png http://www.ajaxupdates.com/wp-content/plugins/sociofluid/images/myspace_32.png http://www.ajaxupdates.com/wp-content/plugins/sociofluid/images/facebook_32.png http://www.ajaxupdates.com/wp-content/plugins/sociofluid/images/sphinn_32.png http://www.ajaxupdates.com/wp-content/plugins/sociofluid/images/mixx_32.png http://www.ajaxupdates.com/wp-content/plugins/sociofluid/images/twitter_32.png

Related Listings:

  1. Pulling Your Flickr Feed with jQuery Feeds are the easiest way to view updated content, whether...
  2. Flickr Like Edit in Place How to edit in place using AJAX? If you are...

Do you like this post?

Email:     

Tags: , , , , , , , , , , , , , , , , , , , ,

No Comments »

No comments yet.

RSS feed for comments on this post. TrackBack URL

Leave a comment



Web Design & CSS (Templates) - TOP.ORG