colorbox-insert-image.tpl.php 1.0 KB

123456789101112131415161718192021222324
  1. <?php
  2. /**
  3. * @file
  4. * Template file for Colorbox content inserted via the Insert module.
  5. *
  6. * Available variables:
  7. * - $item: The complete item being inserted.
  8. * - $image_path: The URL to the image.
  9. * - $link_path: The URL to the image that Colorbox should open.
  10. * - $class: A set of classes assigned to this image (if any).
  11. * - $gallery_id: The ID of the Colorbox gallery.
  12. *
  13. * Note that ALT and Title fields should not be filled in here, instead they
  14. * should use placeholders that will be updated through JavaScript when the
  15. * image is inserted.
  16. *
  17. * Available placeholders:
  18. * - __alt__: The ALT text, intended for use in the <img> tag.
  19. * - __title__: The Title text, intended for use in the <img> tag.
  20. * - __description__: A description of the image, sometimes used as a caption.
  21. */
  22. ?>
  23. <a href="<?php print $link_path; ?>" title="__title__" class="colorbox colorbox-insert-image" rel="<?php print $gallery_id; ?>"><img typeof="foaf:Image" src="<?php print $image_path; ?>" alt="__alt__" title="__title__" class="<?php print $class; ?>" /></a>