Middlebury

Drupal Instagram

Revision as of 15:00, 17 March 2015 by Ian McBride (talk | contribs)

The Instagram content type allows you to display a list of image from one or multiple Instagram accounts, ordered from most to least recent, at a variety of widths. When you first create your Instagram Widget we'll pull in all of the images from the accounts you specify and show a certain number of them, according to your settings. Every hour our site will check with Instagram to see if there are any new images from these accounts and, if so, add them.

Creating an Instagram Widget

Creating a new Instagram Widget works like creating any other type of content in our Drupal sites.

  1. Browse to the page where you want to add this item and log in.
  2. In the blue Content section of the Edit Console ribbon, click Add.
  3. Select Instagram from the list of content types in the center of the page.
  4. Give this item a Title, e.g. "Midd on Instagram".
  5. (optional) Enter some body text. This will be displayed above the list of images from Instagram.
  6. Enter the Users on Instagram to pull images from. The values here are the usernames of the Instagram accounts, e.g. middleburycollege.
    1. If you would like to show images from more than one Instagram account, click the Add another item button and add each of the usernames on their own line.
  7. Enter the number of Images to Show in your widget. The widget will show this many images, choosing the most recent images from the Users you added previously.
  8. Enter the Width of Images, in pixels, as you'd like them to appear on the site. This, combined with the Images to Show setting will determine the number of rows and columns of images that will appear.

Images to Show

You can decide how many images will appear in your Instagram widget and that number will be selected from the most recent images of the users you specify, combined. Here's an example, using two accounts, middleburycollege and middleburyinstitute. Let's say you choose to show 6 images and the two accounts have images taken at these times (assume the time zone difference has been accounted for):

middleburycollege middleburyinstitute
March 15 3pm March 15 4pm
March 15 2pm March 12 3pm
March 15 1pm March 11 5pm
March 12 9am March 10 6pm
March 5 8pm March 1 2pm

The items in bold will be shown on the widget as they are the six most recent images from the two accounts, combined.

Width of Images

Combined with the Images to Show field, this can be used to create a grid of images with a certain number of rows and columns. Consider an Instagram Widget in a Right Sidebar region, which allows content to be 180px wide. If you set the Images to Show value to 12, you could do any of these configurations:

  • 1 column, 12 rows of images at 180px wide
  • 2 columns, 6 rows of images at 90px wide
  • 3 columns, 4 rows of images at 60px wide
  • 4 columns, 3 rows of images at 45px wide

And so on. See our Drupal Region Dimensions documentation to get the full content width values for each region on the page.

Powered by MediaWiki