PHP OIDC Client
  • PHP Oidc-Client
    • Introduction
    • Requirements
    • Supported functionnality
    • How to install
  • How to use the library
    • Generic use of the library
    • Microsoft Azure OIDC
    • Google
    • Github
    • Dropbox
  • Deal with the provider
    • Authorization flow
    • Token endpoint
    • Tokens managment
    • UserInfo
    • Logout
  • Advanced Topic
    • Secure the session
    • Request options
    • Nested JWT
    • UserInfo response encrypted (JWE)
  • Utils
    • LogLevel
    • Generate a key pair
    • Generate an UUID
    • Generate a security key
    • Get informations of a certificate
    • Verify if json
  • Links / Credits
    • Repo
    • OIDC specs
    • JWT Framework
    • Guzzle
Powered by GitBook
On this page
  1. Utils

Verify if json

You can veritfy if a string is a json. The response is a boolean.

use Svgta\OidcLib\OidcUtils;

$isJson = Oidcutils::isJson('My string');
// false;
$isJson = Oidcutils::isJson('{"key": "first", "value": "test"}');
// true;
PreviousGet informations of a certificate

Last updated 1 year ago