PHP code example of njt / good-reads

1. Go to this page and download the library: Download njt/good-reads 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/ */

    

njt / good-reads example snippets


$gr->bookByISBN("ISBN");
$gr->book("id");

$gr->searchBook("Search any think");
$gr->searchBookByName("Book Name");
$gr->searchBookByAuthorName('Author Name');

$author = $gr->authorByID("id");

$books = $gr->authorBooks("id");

$id = $gr->authorIDByName("Author Name");

$author = $gr->authorByName("Author Name");

$series = $gr->seriesByAuthor("id");

$review = $gr->review('id');

$review = $gr->userReviewByBook('userID', 'bookID');

$user = $gr->userInfoByID('id');

$user = $gr->userInfoByUsername('username');

$group = $gr->group('id', 'sort');

$groups = $gr->findGroup('group Name');

$groups = $gr->groupsOfUser('userID', 'sort');

$members = $gr->groupMembers('id');
 php
$gr = new GoodReads('api_key');