I'm not sure if anyone else has that issue: reloading the zone containing
kaptcha component does not trigger image reloading, so the whole thing
becomes unusable (because internal CAPTCHA text is already different, but
image is not). This affects ONLY Firefox, all the other major browsers are
OK. Don't have an idea why (probably Firefox doesn't respect cache control
headers because of some reasons).

After spending some time to fix it, I've ended up with simple
copy-and-paste versions of KaptchaField and KaptchaImage classes with only
one small difference in KaptchaImage:


    boolean beginRender(MarkupWriter writer)

    {

        captchaText = producer.createText();



        Link link = resources.createEventLink("image",
RandomStringUtils.randomAlphanumeric ( 8 ) );


        writer.element("img",


                "src", link.toURI(),


                "width", producer.getWidth(),


                "height", producer.getHeight());


        resources.renderInformalParameters(writer);


        writer.end();


        return false;

    }

It might be a good idea to fix it in the main branch.

-- 
Ilya Obshadko

Reply via email to