-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathb-get-states.php
More file actions
32 lines (24 loc) · 781 Bytes
/
Copy pathb-get-states.php
File metadata and controls
32 lines (24 loc) · 781 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
<?php
/**
* In this example we'll see how to fetch states.
* We can use this information to find radio stations.
*/
use AdinanCenci\RadioBrowser\RadioBrowser;
//-----------------------------
error_reporting(E_ALL);
ini_set('display_errors', 1);
//-----------------------------
require '../vendor/autoload.php';
//-----------------------------
$browser = new RadioBrowser();
$filter = 'Texas'; // optional
$country = ''; // optional
$orderBy = 'name'; // optional
$reverse = true; // ( decrescent ) optional
$hideBroken = false; // Optional
$offset = 0; // optional
$limit = 50; // optional
$data = $browser->getStates($filter, $country, $orderBy, $reverse, $hideBroken);
echo '<pre>';
print_r($data);
echo '</pre>';