diff options
author | Chris Raynor <chris@firebase.com> | 2014-08-25 09:12:03 -0700 |
---|---|---|
committer | Chris Raynor <chris@firebase.com> | 2014-08-25 09:12:03 -0700 |
commit | fdf4b1826574cb15668f723c232cd6ffaad685f4 (patch) | |
tree | aba2412661878fc9f16c82b2021a0f9e40861195 | |
parent | fa7e362eeeec5ee808124626c3f1a612aadbce52 (diff) | |
parent | ef310516c4f632d0c8289ccdf4150bc44dad4267 (diff) | |
download | php-jwt-fdf4b1826574cb15668f723c232cd6ffaad685f4.zip php-jwt-fdf4b1826574cb15668f723c232cd6ffaad685f4.tar.gz php-jwt-fdf4b1826574cb15668f723c232cd6ffaad685f4.tar.bz2 |
Merge pull request #14 from firebase/object-docs
Adding documentation around casting the result to an associative array
-rw-r--r-- | README.md | 8 |
1 files changed, 8 insertions, 0 deletions
@@ -31,6 +31,14 @@ $jwt = JWT::encode($token, $key); $decoded = JWT::decode($jwt, $key); print_r($decoded); + +/* + NOTE: This will now be an object instead of an associative array. To get + an associative array, you will need to cast it as such: +*/ + +$decoded_array = (array) $decoded; + ?> ``` |