Peter's Blog

Redefining the Impossible

Drupal Flickr Block


I saw in my logs that someone was searching on my site on how to create a Drupal block for flickr. It's easy:

  • On your flickr account, create a badge
  • Copy the badge code
  • in Drupal, create a block of type 'php' and paste the flickr code into it.

This will show selected or random photos in a selection of sizes. It works very nicely.

I chose to centre the pictures in the block by surrounding the code in a centred div:

<div style="text-align: center">
[flick code]
</div>

Filed under: drupal flickr php

Anonymous Says:

over 3 years ago

woo i like that :>

Adam Gurno Says:

over 2 years ago

I used this advice to create a flash badge @ gurno.com. I modified the given CSS to center the badge within the block. (margin-left,margin-right:auto;)

Awesome - very cool. Flickr (and Drupal) continue to impress.

Jared Says:

6 months ago

so.... let's see a link to it!

Peter Says:

6 months ago

Ask nicely.

Peter

buyerjoy Says:

6 months ago

Thank you! I use it @ www.buyerjoy.com . The badge is great!

Comments are Closed