leafs/cookie
最新稳定版本:v4.0
Composer 安装命令:
composer require leafs/cookie
包简介
Leaf PHP cookie module
README 文档
README
Leaf Cookie Module
Leaf's cookie module provides a wrapper around the built-in PHP cookie functions. It provides a cleaner and more expressive API working with cookies while maintaining full compatibility with PHP's built-in cookie functions.
Installation
You can easily install Leaf using Composer.
composer require leafs/cookie
Usage
Once installed, it merges with Leaf's core, so you can use it like so:
response() ->withCookie('name', 'Fullname') ->withCookie('age', 20) ->json([ 'message' => 'Cookies set' ]);
Or on its own:
cookie()->set('name', 'Fullname', [ 'expire' => time() + 3600, 'path' => '/', 'domain' => 'example.com', 'secure' => true, 'httponly' => true, 'samesite' => 'None' ]);
Stay In Touch
Learning Leaf PHP
- Leaf has a very easy to understand documentation which contains information on all operations in Leaf.
- You can also check out our youtube channel which has video tutorials on different topics
- You can also learn from codelabs and contribute as well.
Contributing
We are glad to have you. All contributions are welcome! To get started, familiarize yourself with our contribution guide and you'll be ready to make your first pull request 🚀.
To report a security vulnerability, you can reach out to @mychidarko or @leafphp on twitter. We will coordinate the fix and eventually commit the solution in this project.
Sponsoring Leaf
We are committed to keeping Leaf open-source and free, but maintaining and developing new features now requires significant time and resources. As the project has grown, so have the costs, which have been mostly covered by the team. To sustain and grow Leaf, we need your help to support full-time maintainers.
You can sponsor Leaf and any of our packages on open collective or check the contribution page for a list of ways to contribute.
And to all our existing cash/code contributors, we love you all ❤️
统计信息
- 总下载量: 3.01k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 2
- 点击次数: 1
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2021-09-20