PHP code example of zestic / graphql-simple-client

1. Go to this page and download the library: Download zestic/graphql-simple-client library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

zestic / graphql-simple-client example snippets


$categories = $response->allCategories->category;

foreach($categories as $category) {
    // Do something with the data?
    $category->id;
    $category->name;
    $category->slug;
    $category->description;
}