Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Unexpected control character found
- try {
- $secretKey = 'hayderZainCash';
- $headers = apache_request_headers();
- $token = $headers['Authorization'];
- $credintials = JWT::decode($token, $secretKey, array('HS256'));
- echo $credintials;
- } catch (Exception $e) {
- echo 'error ' . $e->getMessage();
- }
- preg_match('/Bearers(S+)/', $headers['Authorization'], $matches);
- $token = $matches[0];
- try
- {
- $secretKey = 'hayderZainCash';
- $headers = apache_request_headers();
- preg_match('/Bearers(S+)/', $headers['Authorization'], $matches);
- $credintials = JWT::decode($matches[0], $secretKey, array('HS256'));
- print_r($credintials);
- }
- catch( Exception $e )
- {
- echo 'error ' . $e->getMessage();
- }
Add Comment
Please, Sign In to add comment