You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+13-28Lines changed: 13 additions & 28 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,5 +1,4 @@
1
-
FIG Cookies
2
-
===========
1
+
# FIG Cookies
3
2
4
3
Managing Cookies for PSR-7 Requests and Responses.
5
4
@@ -15,20 +14,16 @@ Managing Cookies for PSR-7 Requests and Responses.
15
14
<br>
16
15
[](https://gitter.im/dflydev/dflydev-fig-cookies?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
17
16
18
-
19
-
Installation
20
-
------------
17
+
## Installation
21
18
22
19
```bash
23
20
$> composer require dflydev/fig-cookies
24
21
```
25
22
23
+
## Concepts
26
24
27
-
Concepts
28
-
--------
29
-
30
-
FIG Cookies tackles two problems, managing **Cookie***Request* headers and
31
-
managing **Set-Cookie***Response* headers. It does this by way of introducing
25
+
FIG Cookies tackles two problems, managing **Cookie**_Request_ headers and
26
+
managing **Set-Cookie**_Response_ headers. It does this by way of introducing
32
27
a `Cookies` class to manage collections of `Cookie` instances and a
33
28
`SetCookies` class to manage collections of `SetCookie` instances.
34
29
@@ -66,9 +61,7 @@ verbose very quickly. In order to get around that, FIG Cookies provides
66
61
two facades in an attempt to help simplify things and make the whole process
67
62
less verbose.
68
63
69
-
70
-
Basic Usage
71
-
-----------
64
+
## Basic Usage
72
65
73
66
The easiest way to start working with FIG Cookies is by using the
74
67
`FigRequestCookies` and `FigResponseCookies` classes. They are facades to the
@@ -81,7 +74,6 @@ process so be wary of using too many of these calls in the same section of
81
74
code. In some cases it may be better to work with the primitive FIG Cookies
82
75
classes directly rather than using the facades.
83
76
84
-
85
77
### Request Cookies
86
78
87
79
Requests include cookie information in the **Cookie** request header. The
Delivery of the rendered `SetCookie` instances is the responsibility of the
291
282
PSR-7 client implementation.
292
283
293
-
294
284
### Do you do anything with sessions?
295
285
296
286
No.
297
287
298
288
It would be possible to build session handling using cookies on top of FIG
299
289
Cookies but it is out of scope for this package.
300
290
301
-
302
291
### Do you read from `$_COOKIES`?
303
292
304
293
No.
@@ -310,18 +299,14 @@ implementations should be including `$_COOKIES` values in the headers
310
299
so in that case FIG Cookies may be interacting with `$_COOKIES`
311
300
indirectly.
312
301
313
-
314
-
License
315
-
-------
302
+
## License
316
303
317
304
MIT, see LICENSE.
318
305
319
-
320
-
Community
321
-
---------
306
+
## Community
322
307
323
308
Want to get involved? Here are a few ways:
324
309
325
-
* Find us in the #dflydev IRC channel on irc.freenode.org.
326
-
* Mention [@dflydev](https://twitter.com/dflydev) on Twitter.
327
-
*[](https://gitter.im/dflydev/dflydev-fig-cookies?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
310
+
- Find us in the #dflydev IRC channel on irc.freenode.org.
311
+
- Mention [@dflydev](https://twitter.com/dflydev) on Twitter.
312
+
-[](https://gitter.im/dflydev/dflydev-fig-cookies?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
0 commit comments