Captcha In The Layout (Global Captcha)

Hi!

It gets a hard long time to find out that every Captcha belongs to a controller. Now I have a little contact form in footer of site. ContactController is responsible for this form. How to generate a Captcha that can be validate by this controller, but render in every single action of other controllers? I’ve found a ‘controller’ property in CCaptcha but it’s read-only…

just provide ‘captchaAction’ parameter to CCaptcha widget as ‘contact/captcha’ (controller/action) and it should work fine.

Please go through this link, this will help you