|
@@ -13,16 +13,14 @@ public class ImageVerifyCodeConfig {
|
|
public DefaultKaptcha getKaptchaBean(){
|
|
public DefaultKaptcha getKaptchaBean(){
|
|
DefaultKaptcha defaultKaptcha=new DefaultKaptcha();
|
|
DefaultKaptcha defaultKaptcha=new DefaultKaptcha();
|
|
Properties properties=new Properties();
|
|
Properties properties=new Properties();
|
|
- properties.setProperty("kaptcha.border.color", "white");
|
|
|
|
- properties.setProperty("kaptcha.noise.color", "55,154,56");
|
|
|
|
- properties.setProperty("kaptcha.textproducer.font.color", "55,154,56");
|
|
|
|
- properties.setProperty("kaptcha.background.clear.from", "white");
|
|
|
|
- properties.setProperty("kaptcha.background.clear.to", "white");
|
|
|
|
|
|
+ properties.setProperty("kaptcha.border", "yes");
|
|
|
|
+ properties.setProperty("kaptcha.border.color", "105,179,90");
|
|
|
|
+ properties.setProperty("kaptcha.textproducer.font.color", "blue");
|
|
properties.setProperty("kaptcha.image.width", "125");
|
|
properties.setProperty("kaptcha.image.width", "125");
|
|
properties.setProperty("kaptcha.image.height", "45");
|
|
properties.setProperty("kaptcha.image.height", "45");
|
|
properties.setProperty("kaptcha.session.key", "code");
|
|
properties.setProperty("kaptcha.session.key", "code");
|
|
properties.setProperty("kaptcha.textproducer.char.length", "4");
|
|
properties.setProperty("kaptcha.textproducer.char.length", "4");
|
|
- properties.setProperty("kaptcha.textproducer.char.space", "4");
|
|
|
|
|
|
+ properties.setProperty("kaptcha.textproducer.font.names", "宋体,楷体,微软雅黑");
|
|
Config config=new Config(properties);
|
|
Config config=new Config(properties);
|
|
defaultKaptcha.setConfig(config);
|
|
defaultKaptcha.setConfig(config);
|
|
return defaultKaptcha;
|
|
return defaultKaptcha;
|