cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Vadim Gritsenko <va...@reverycodes.com>
Subject Re: svn commit: r170589 - in /cocoon/branches/BRANCH_2_1_X/src/blocks/forms: conf/ java/org/apache/cocoon/forms/formmodel/ java/org/apache/cocoon/forms/validation/impl/
Date Wed, 18 May 2005 00:56:14 GMT
ugo@apache.org wrote:
> + * A {@link Field} for CAPTCHA validation. Upon generation, a secret random string is
stored
> + * in a session attribute having the same name as the field's ID, for use by a 
> + * {@link org.apache.cocoon.forms.validation.impl.CaptchaValidator}.

> +        Session session = ObjectModelHelper.getRequest(objectModel).getSession(true);
> +        session.setAttribute(SESSION_ATTR_PREFIX + getId(), generateSecret());

Such session attribute name is not unique (two forms with similar widget id). 
Why not use widget.set/getAttribute?

Vadim

Mime
View raw message