struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Laurie Harper <lau...@holoweb.net>
Subject Re: JCAPTCHA
Date Mon, 02 Jun 2008 20:49:40 GMT
Looks like the JCaptcha documentation you followed is inconsistent with 
the version of JCaptcha you are using. In any case, it's a JCaptcha 
issue rather than a Struts one, and you're probably better off asking on 
their forms / user lists.

L.

cacodemon79 wrote:
> Hi, i'm using jcaptcha with Struts 1.3.
> I already configured my web application following the suggestions present at
> the JCAPTCHA homepage and all works.
> 
> Now, I'd like to customize the captcha: I'd like to use another engine than
> the default one and try to change other options (size, colour, ...).
> 
> I tried to follow the suggestion present at the JCAPTCHA homepage:
> 
> 
> Basically follow these steps to use another engine in struts:
> 
> 1) create a new service class like this:
> 
> package mypackage;
> import com.octo.captcha.engine.image.gimpy.SimpleListImageCaptchaEngine;
> 
> import com.octo.captcha.service.image.EhcacheManageableImageCaptchaService;
> 
> import com.octo.captcha.service.image.ImageCaptchaService;
> 
> public class MyOwnManageableImageCaptchaService extends
> EhcacheManageableImageCaptchaService
> 
> implements ImageCaptchaService {
> 
> 	public MyOwnManageableImageCaptchaService() {
> 		super(new SimpleListImageCaptchaEngine(), 180, 100000);
> 	}}and here pass the wished engine (here SimpleListImageCaptchaEngine which
> I like best) to the superclass...
> 
> 2) in the strus-config.xml pass the new service class to the
> CaptchaServicePlugin like this:
> 
> <plug-in className="com.octo.captcha.module.struts.CaptchaServicePlugin">
>       <set-property property="serviceClass"
>           value="mypackage.MyOwnManageableImageCaptchaService" />
>   </plug-in>
> 
> but I got some errors/warnings:
> - The type MyOwnManageableImageCaptchaService must implement the inherited
> abstract method ManageableCaptchaService.setCaptchaEngine(CaptchaEngine)
> - The type EhcacheManageableImageCaptchaService is deprecated
> - The constructor EhcacheManageableImageCaptchaService(CaptchaEngine, int,
> int) is deprecated
> 
> How can I solve this problem?
> 
> Can you help me?
> 
> Thanks a lot in advance. 


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Mime
View raw message