mollom-captcha-image.tpl.php 1.4 KB

123456789101112131415161718192021222324252627282930
  1. <?php
  2. /**
  3. * @file
  4. * Provide the HTML output for the CAPTCHA image display.
  5. *
  6. * Available variables:
  7. * - $captcha_url: The CAPTCHA image to present based
  8. * - $audio_enabled: boolean indicates if audio CAPTCHAs are enabled
  9. * for this site.
  10. */
  11. $switch_verify = $audio_enabled ? t('Switch to audio verification.') : '';
  12. $instructions = t("Type the characters you see in the picture; if you can't read them, submit the form and a new image will be generated. Not case sensitive.");
  13. $image_alt_text = t('Type the characters you see in this picture.');
  14. $refresh_alt = t('Refresh');
  15. ?>
  16. <?php
  17. $refresh_image_output = theme('image', array(
  18. 'path' => drupal_get_path('module', 'mollom') . '/images/refresh.png',
  19. 'alt' => $refresh_alt,
  20. 'getsize' => FALSE,
  21. ));
  22. $captcha_output = theme('image', array('path' => $captcha_url, 'alt' => $image_alt_text, 'getsize' => FALSE));
  23. ?>
  24. <span class="mollom-captcha-container">
  25. <a href="javascript:void(0);" class="mollom-refresh-captcha mollom-refresh-image"><?php print $refresh_image_output; ?></a>
  26. <span class="mollom-captcha-content mollom-image-captcha"><?php print $captcha_output; ?></span>
  27. <span class="mollom-image-captcha-instructions"><?php print $instructions; ?><?php if ($audio_enabled) { ?>&nbsp;&nbsp;<a href="#" class="mollom-switch-captcha mollom-audio-captcha"><?php print $switch_verify; ?></a><?php } ?></span>
  28. </span>