Skip to content

Commit f795980

Browse files
committed
Fixed variables and test cases.
1 parent a8a577b commit f795980

File tree

3 files changed

+86
-244
lines changed

3 files changed

+86
-244
lines changed

examples/example.php

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,12 @@
33
require 'vendor/autoload.php';
44

55
// Lookup by local BIN database
6-
$db = new \IP2Proxy\Database('vendor/ip2location/ip2proxy-php/data/PX10.SAMPLE.BIN', \IP2PROXY\Database::FILE_IO);
6+
$db = new \IP2Proxy\Database('./data/PX10.SAMPLE.BIN', \IP2PROXY\Database::FILE_IO);
77

8-
echo 'Get All Fields' . PHP_EOL;
8+
echo 'Module Version: ' . $db->getModuleVersion() . PHP_EOL. PHP_EOL;
9+
echo 'Package: PX'. $db->getPackageVersion() . PHP_EOL;
10+
echo 'Database Date: ' . $db->getDatabaseVersion() . PHP_EOL;
11+
echo '$records = $db->lookup(\'1.0.0.8\', \IP2PROXY\Database::ALL);' . PHP_EOL;
912
$records = $db->lookup('1.0.0.8', \IP2PROXY\Database::ALL);
1013
print_r($records);
1114

0 commit comments

Comments
 (0)