|
@@ -44,15 +44,17 @@ public class VerifyCode {
|
|
}
|
|
}
|
|
|
|
|
|
// 随机生成三个数字、并组合成一个数学公式
|
|
// 随机生成三个数字、并组合成一个数学公式
|
|
- String verifyCode = new StringBuilder()
|
|
|
|
- .append(random.nextInt(10))
|
|
|
|
- .append(OPS[random.nextInt(2)])
|
|
|
|
- .append(random.nextInt(10))
|
|
|
|
- .append(OPS[random.nextInt(2)])
|
|
|
|
- .append(random.nextInt(10))
|
|
|
|
- .append(OPS[random.nextInt(2)])
|
|
|
|
- .append(random.nextInt(10))
|
|
|
|
- .toString();
|
|
|
|
|
|
+// String verifyCode = new StringBuilder()
|
|
|
|
+// .append(random.nextInt(10))
|
|
|
|
+// .append(OPS[random.nextInt(2)])
|
|
|
|
+// .append(random.nextInt(10))
|
|
|
|
+// .append(OPS[random.nextInt(2)])
|
|
|
|
+// .append(random.nextInt(10))
|
|
|
|
+// .append(OPS[random.nextInt(2)])
|
|
|
|
+// .append(random.nextInt(10))
|
|
|
|
+// .toString();
|
|
|
|
+
|
|
|
|
+ String verifyCode = "1+2+3+4";
|
|
|
|
|
|
graphics.setColor(new Color(0, 0, 255));
|
|
graphics.setColor(new Color(0, 0, 255));
|
|
graphics.setFont(new Font("Candara", Font.BOLD, 22));
|
|
graphics.setFont(new Font("Candara", Font.BOLD, 22));
|