PHP Classes

File: test_pictcapt.php

Recommend this page to a friend!
  Classes of Patricio Cardó  >  Pict CAPTCHA  >  test_pictcapt.php  >  Download  
File: test_pictcapt.php
Role: Example script
Content type: text/plain
Description: example and test
Class: Pict CAPTCHA
CAPTCHA validation making the user select pictures
Author: By
Last change:
Date: 9 years ago
Size: 1,106 bytes


Class file image Download
$alerta = "";
$capt_conf = array(
"phrases"=> array("help"=>"ayuda", "reload"=>"recargar dibujo")
$capt = new pict_captcha($capt_conf);

$exito = ($capt->verify())?"Bien":"Mal";
$alerta .= "<div style='width:400px;background-color:#ffffdd;font-family:Arial'>".$exito."</div>";
$ifr = $capt->gethtml();

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
<html xmlns='' xml:lang='es' lang='es' >
    <meta http-equiv='content-type' content='text/html; charset=UTF-8' />
print $alerta;
"<h1>Testing pict_captcha</h1>
    <form action='"
.$_SERVER["PHP_SELF"]."' method='post'>
        <td>Select the images represented in the drawing</td>
        <td style='background-color:#eeeeee'>
    <input type='submit' name='captcha'/>

For more information send a message to info at phpclasses dot org.