Skip to content

Commit db143a2

Browse files
committed
Update README.md
add document
1 parent 23d13c4 commit db143a2

File tree

1 file changed

+19
-1
lines changed

1 file changed

+19
-1
lines changed

README.md

+19-1
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,20 @@
11
captcha
2-
=======
2+
=======
3+
4+
使用方法之一
5+
------------
6+
7+
直接复制captcha.php到你的项目中,用img标签引用captcha.php,即可出现验证码
8+
9+
<code>
10+
&lt;img src="./captcha.php" width="175" height="45" /&gt;
11+
</code>
12+
13+
captcha.php会自动使用$_SESSION['captcha']来保存验证码,请自行写代码在收到请求时验证相应字段。
14+
15+
使用方法之二
16+
------------
17+
18+
在你的项目中包含datauricaptcha.php。
19+
20+
getCaptcha()函数可以返回一个关联数组,其"question"字段是验证码图片的datauri,其"answer"字段是验证码的文本。你可以根据需要使用。

0 commit comments

Comments
 (0)