定制 kegi/netscape-cookie-file-handler 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

kegi/netscape-cookie-file-handler

最新稳定版本:1.0.3

Composer 安装命令:

composer require kegi/netscape-cookie-file-handler

包简介

Netscape Cookie File Handler

README 文档

README

Build Status Latest Stable Version Test Coverage

Issue Count Code Climate SensioLabsInsight

This library allows you to manipulate Netscape Cookie File (eg. Cookies generated by CURL).

Requirements

This is library is only available for PHP7+ There is no other dependencies

Installation

This library is available on packagist (Composer)

composer require kegi/netscape-cookie-file-handler

What are Cookies Files ?

The Netscape cookie files are widely used. Curl, by example, allows you to select a file (called the cookie jar) to save and read the cookies using this format. This library will help you to manipulate and read those cookies.

Example

Simple example of reading + writing cookies

/*Open and parse the cookie file*/ $configuration = (new Configuration())->setCookieDir('cookies/'); $cookieJar = (new CookieFileHandler($configuration))->parseFile('my_cookie_file'); /*Add (and save) a cookie*/ $cookieJar->add( (new Cookie()) ->setHttpOnly(true) ->setPath('/foo') ->setSecure(true) ->setExpire(new DateTime('2020-02-20 20:20:02')) ->setName('foo') ->setValue('bar') )->persist();

Documentation

Learn how to use the library here : documentation.

Contribution

Feel free to contact me or send pull requests !

统计信息

  • 总下载量: 7.32k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 23
  • 点击次数: 2
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 23
  • Watchers: 2
  • Forks: 3
  • 开发语言: PHP

其他信息

  • 授权协议: GPL-3.0
  • 更新时间: 2026-01-04

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固