This module provides a Zoetrope ID field, field formatters and tokens for putting zoetrope engage viewers in to drupal entities
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.


Zoetrope Viewer Module

The Zoetrope viewer module provides fields, field formatters and tokens for the
zoetrope viewer. It's made specifically for use with the engage photography
service from

1. Entity Tokens, if tokens are required

 * Install as you would normally install a contributed drupal module. See:
  for further information.

Add a `Zoetrope ID` field to an entity, using the `Zoetrope Engage Viewer` as
the display type.

Zoetrope images are always square, though the size is configurable, using
standard image styles. Image styles are not actually processed for Zoetrope
images - only the sizes are honored. Any changes to the image styling need to
be done with CSS or by using an alternate trigger image.

If you wish to display a Zoetrope image if it exists, or fall back to a static
shot if it doesn't, this should be done using a template file.
e.g. if your engage image field is called `field_zoetrope_engage_image` and your
legacy/backup image field is called `field_image`.

  <?php if (empty($content['field_zoetrope_engage_image'])) {?>
    <div class="product-image flat-shot">
      <?php render($content['field_image']); ?>
  <?php }
    else {?>
    <div class="product-image engage">
      <?php render($content['field_zoetrope_engage_image']); ?>
  <?php } ?>

If you want to combine a list of regular images with Zoetrope images for
display, an image formatter `Image + Zoetrope Images` is provided to merge a
Zoetrope ID field into an image field for display.

The main use case for the tokens in this module is to use them in conjunction
with the metatags module.

Provided Tokens (replace node with any entity type, e.g. commerce_product,
if you have an image on a commerce_product):
*. `[node:field_name:preveiw_uri]` - The 1000px preview image url
*. `[node:field_name:zoetrope_uuid]` - The Zoetrope UUID of the image
*. `[node:field_name:starting_position]` - The index of the starting position