Closed ericlucit closed 4 years ago
I have a header attached to an email formatted as such
X-MyHeader : {"some_id":2,"some_othger_id":"0dd75231-31bb-4e67-8ab7-a83315f75a44","some_field":"A Field Value"}
When using the getHeader("X-MyHeader") - I receive only {"some_id"
getHeader("X-MyHeader")
{"some_id"
Accoding to the RFC for Email Headers RFC 822, Section 3.1.2 :
The field-body may be composed of any ASCII characters, except CR or LF.
I think the issue is in the following line of code:
list($key, $value) = explode(":", $header.":");
Which could be changed to
list($key, $value) = explode(":", $header.":", 2);
which would limit the array to the first colon found
Thanks for the report! Fixed in version 4.0.9
Thanks! - Worked perfect
I have a header attached to an email formatted as such
X-MyHeader : {"some_id":2,"some_othger_id":"0dd75231-31bb-4e67-8ab7-a83315f75a44","some_field":"A Field Value"}
When using the
getHeader("X-MyHeader")
- I receive only{"some_id"
Accoding to the RFC for Email Headers RFC 822, Section 3.1.2 :
I think the issue is in the following line of code:
Which could be changed to
which would limit the array to the first colon found