Text_CAPTCHA
[ class tree: Text_CAPTCHA ] [ index: Text_CAPTCHA ] [ all elements ]

Class: Text_CAPTCHA_Driver_Numeral

Source Location: /Text_CAPTCHA-1.0.2/Text/CAPTCHA/Driver/Numeral.php

Class Overview

Text_CAPTCHA_Driver_Base
   |
   --Text_CAPTCHA_Driver_Numeral

Class used for numeral captchas


Author(s):

Methods


Inherited Variables

Inherited Methods

Class: Text_CAPTCHA_Driver_Base

Text_CAPTCHA_Driver_Base::getCAPTCHA()
Place holder for the real getCAPTCHA() method used by extended classes to return the generated CAPTCHA (as an image resource, as an ASCII text, ...)
Text_CAPTCHA_Driver_Base::getPhrase()
Return secret CAPTCHA phrase This method returns the CAPTCHA phrase
Text_CAPTCHA_Driver_Base::resetDriver()
Reset the phrase and the CAPTCHA.
Text_CAPTCHA_Driver_Base::setCaptcha()
Sets the generated captcha.
Text_CAPTCHA_Driver_Base::setPhrase()
Sets secret CAPTCHA phrase.

Class Details

[line 31]
Class used for numeral captchas

This class is intended to be used to generate numeral captchas as such as: Example: Give me the answer to "54 + 2" to prove that you are human.



[ Top ]


Method Detail

createCAPTCHA   [line 129]

void createCAPTCHA( )

Create the CAPTCHA (the numeral expression).

This function determines a random numeral expression and set the associated class properties.

  • See: _generateOperation()
  • See: _generateFirstNumber()
  • See: _generateOperator()
  • See: _generateSecondNumber()
  • Access: public

[ Top ]

createPhrase   [line 264]

string createPhrase( )

Create random CAPTCHA phrase. This method is a placeholder, since the equation is created in createCAPTCHA()
  • Access: public

[ Top ]

initDriver   [line 88]

void initDriver( [array $options = array()])

Initialize numeric CAPTCHA.
  • Access: public

Parameters:

array   $options     CAPTCHA options with these keys:
minValue minimum value
maxValue maximum value

[ Top ]


Documentation generated on Fri, 28 Feb 2014 16:00:04 +0000 by phpDocumentor 1.4.3. PEAR Logo Copyright © PHP Group 2004.