中
$request->session()->set('captcha', strtolower($builder->getPhrase()));
// 获得验证码图片二进制数据$img_content = $builder->get();
// 输出验证码二进制数据
return response($img_content,text" name="captcha" />
<input type="submit" value="提交" />
</form>
</body>
</html>
```
进入页面/assets/img/captcha.png)
## 常见参数设置
```php
/**
* 输出验证码图像
*/
public function captchaget();
return response($img_content, 200, ['Content-Type' => 'image/jpeg']);
}
```
更多接口及参数参考