PHP code example of ralph / marvel
1. Go to this page and download the library: Download ralph/marvel 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/ */
ralph / marvel example snippets
use Ralph\Marvel;
$config = [
'publicKey' => '***',
'privateKey' => '*******',
];
$marvel = new Marvel($config);
$options = [
'limit' => 10,
];
// Fetches lists of comic characters with optional filters.
$characters = $marvel->characters($options);
// Fetches lists of comics with optional filters.
$comics = $marvel->comics($options);
// Fetches lists of comic creators with optional filters.
$creators = $marvel->creators($options);
// Fetches lists of events with optional filters.
$events = $marvel->events($options);
// Fetches lists of comic series with optional filters.
$series = $marvel->series($options);
// Fetches lists of comic stories with optional filters.
$stories = $marvel->stories($options);