Question

Im NOT wanting to use recaptcha, or install a captcha, i want to use the built-in captcha framework that came as part of joomla 2.5. And add it to my custom forms and extensions.

Was it helpful?

Solution

To add captcha to a form, simply add the captcha field: Assuming your component is com_something:

    <field
        name="captcha"
        type="captcha"
        label="COM_SOMETHING_CAPTCHA_LABEL"
        description="COM_SOMETHING_CAPTCHA_DESC"
        validate="captcha"
        namespace="something"
    />

The validation will handle it transparently for you. Look into com_contact and com_users for examples i.e. components/com_contact/models/forms/contact.xml

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top