/[drupal]/contributions/modules/captcha/captcha_image.inc
ViewVC logotype

Diff of /contributions/modules/captcha/captcha_image.inc

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph | View Patch Patch

revision 1.1, Mon Jan 30 04:38:50 2006 UTC revision 1.2, Fri Mar 3 22:42:41 2006 UTC
# Line 1  Line 1 
1  <?  <?
2    
3  function _captcha_image_challenge(&$form) {  function _captcha_image_challenge(&$form) {
   
   $form['captcha_image'] = array (  
     '#type' => 'item',  
     '#title' =>  'captcha image',  
     '#weight' => 0,  
     '#value' => '<img src="' . url('captcha/image/'.time()) . '"  alt="Captcha Image: you will need to recognize the text in it."/>',  
   );  
   
4    $form['captcha_response'] = array (    $form['captcha_response'] = array (
5      '#type' => 'textfield',      '#type' => 'textfield',
6      '#title' => t('Word'),      '#title' => t('Captcha Validation'),
7      '#defaultvalue' => '',      '#defaultvalue' => '',
     '#weight' => 0,  
8      '#required' => TRUE,      '#required' => TRUE,
9      '#validate' => array('_captcha_validate' => array()),      '#validate' => array('_captcha_validate' => array()),
10      '#description' => t('Please type in the letters/numbers that are shown in the image above.')      '#description' => t('Please type in the letters/numbers that are shown in the image above.'),
11        '#prefix' => '<img src="' . url('captcha/image/'.time()) . '"  alt="Captcha Image: you will need to recognize the text in it."/>',
12    );    );
13    
14    return $form;    return $form;

Legend:
Removed from v.1.1  
changed lines
  Added in v.1.2

  ViewVC Help
Powered by ViewVC 1.1.2