equal
deleted
inserted
replaced
19 * |
19 * |
20 * Avoid using this where commas may be used unquoted in values, such as |
20 * Avoid using this where commas may be used unquoted in values, such as |
21 * Set-Cookie headers. |
21 * Set-Cookie headers. |
22 * |
22 * |
23 * @param string $key |
23 * @param string $key |
24 * @return string Header value |
24 * @return string|null Header value |
25 */ |
25 */ |
26 public function offsetGet($key) { |
26 public function offsetGet($key) { |
27 $key = strtolower($key); |
27 $key = strtolower($key); |
28 if (!isset($this->data[$key])) { |
28 if (!isset($this->data[$key])) { |
29 return null; |
29 return null; |
56 |
56 |
57 /** |
57 /** |
58 * Get all values for a given header |
58 * Get all values for a given header |
59 * |
59 * |
60 * @param string $key |
60 * @param string $key |
61 * @return array Header values |
61 * @return array|null Header values |
62 */ |
62 */ |
63 public function getValues($key) { |
63 public function getValues($key) { |
64 $key = strtolower($key); |
64 $key = strtolower($key); |
65 if (!isset($this->data[$key])) { |
65 if (!isset($this->data[$key])) { |
66 return null; |
66 return null; |