Skip to content

georanker/georanker-api-php

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 

Repository files navigation

GeoRanker API PHP Connector

Usage:

<?PHP 

include("GeoRankerAPI.php");

$grapi = new GeoRankerAPI("email", "apikey");
$loginobj = $grapi->login();
if (empty($loginobj) || isset($loginobj->msg)) {
	echo json_encode($loginobj, JSON_PRETTY_PRINT);
	exit;
}

$reportid = 1117597; 

$reportobj = $grapi->reportget($reportid);

if (empty($reportobj) || isset($reportobj->msg)) {
	echo json_encode($reportobj, JSON_PRETTY_PRINT);
	exit;
}

if (empty($reportobj->is_pending)) {
	// Handle the report object...
	echo json_encode($reportobj, JSON_PRETTY_PRINT);
} else {
	// The report is still pending.
	echo json_encode($reportobj, JSON_PRETTY_PRINT); // Just show a JSON string 
}

About

GeoRanker API PHP Connector

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages