Skip to content
brianhaveri edited this page Sep 14, 2010 · 4 revisions

List of stats methods and parameters

Method Description Parameter Returns
stats_colors Get color stats array $query array
stats_palettes Get palette stats array $query array
stats_patterns Get pattern stats array $query array
stats_lovers Get lover stats array $query array

For stat methods, the parameter $query array can include the following keys:

  • format
  • jsonCallback

More information on $query keys and return values at the ColourLOVERS.com API page

Sample code

require_once('ColourLovers.php');
$c = new ColourLovers;
$results = $c->stats_colors();
print_r($results);
/*
Array
(
    [@attributes] => Array
        (
            [numResults] => 1
            [totalResults] => 1
        )
    [total] => 2436253
)
*/
Clone this wiki locally