Hi,

I am absolutely new to ZF. Right now I am playing around with the
"Quickstart" files. So far I am bit comfortable with the concepts. Now
I want to change the provided zend captcha (figlet) into image type
but can't find any example of this in the zend documentation.

This is what I came up with
========================
        $mycaptcha = New Zend_Form_Element_Captcha('mycaptcha');
        $mycaptcha ->setLabel('Please enter the 5 letters displayed below:');
        $mycaptcha ->setRequired(true);
        $mycaptcha ->setCaptcha('Image', array(
                'font' => 'C:\WINDOWS\FONTS\TAHOMA.TTF',
                'imgdir' => APPLICATION_PATH . '/images/captcha'
            ));
========================

I have created the "images/captcha" folder inside the application path
and expecting to show up the label and image but instead it shows an
unrelated error.

Error message:
==============
An error occurred
Application error
Exception information:

Message: Invalid validator provided to addValidator; must be string or
Zend_Validate_Interface
==============

if I remove the captcha element from the form it works fine.

What is wrong with my code? and where should I look for more
information on this?

Any suggestions/guidance?

Thanks!

-- 
=======================
Registered Linux User #460714
Currently Using Fedora 8, 10
=======================

Reply via email to