insert-image.tpl.php 1.1 KB

123456789101112131415161718192021222324252627
  1. <?php
  2. /**
  3. * @file
  4. * Template file for generic images inserted via the Insert module.
  5. *
  6. * Available variables:
  7. * - $item: The complete item being inserted.
  8. * - $url: The URL to the image.
  9. * - $class: A set of classes assigned to this image (if any).
  10. * - $width: The width of the image.
  11. * - $height: The height of the image.
  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. * - __filename__: The file name.
  22. * - __[token]_or_filename__: Any of the above tokens if available, otherwise
  23. * use the file's name. i.e. __title_or_filename__.
  24. */
  25. ?>
  26. <img src="<?php print $url ?>" width="<?php print $width ?>" height="<?php print $height ?>" alt="__alt__" title="__title__" <?php print $class ? 'class="' . $class . '" ' : '' ?>/>