@@ -3,7 +3,7 @@ |
||
| 3 | 3 | |
| 4 | 4 | $vdir=$_SERVER['DOCUMENT_ROOT'].'/route4me/examples/'; |
| 5 | 5 | |
| 6 | - require $vdir.'/../vendor/autoload.php'; |
|
| 6 | + require $vdir.'/../vendor/autoload.php'; |
|
| 7 | 7 | |
| 8 | 8 | use Route4Me\Route4Me; |
| 9 | 9 | |
@@ -1,7 +1,7 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | 2 | namespace Route4Me; |
| 3 | 3 | |
| 4 | - $vdir=$_SERVER['DOCUMENT_ROOT'].'/route4me/examples/'; |
|
| 4 | + $vdir = $_SERVER['DOCUMENT_ROOT'].'/route4me/examples/'; |
|
| 5 | 5 | |
| 6 | 6 | require $vdir.'/../vendor/autoload.php'; |
| 7 | 7 | |
@@ -10,14 +10,14 @@ discard block |
||
| 10 | 10 | // Set the api key in the Route4Me class |
| 11 | 11 | Route4Me::setApiKey('11111111111111111111111111111111'); |
| 12 | 12 | |
| 13 | - $abLocation=new AddressBookLocation(); |
|
| 13 | + $abLocation = new AddressBookLocation(); |
|
| 14 | 14 | |
| 15 | 15 | //Example for retrieving Address Book Location by address_id |
| 16 | 16 | //--------------------------------------------------------- |
| 17 | - $query=4621569; |
|
| 18 | - $abcResult=$abLocation->getAddressBookLocation($query); |
|
| 17 | + $query = 4621569; |
|
| 18 | + $abcResult = $abLocation->getAddressBookLocation($query); |
|
| 19 | 19 | |
| 20 | - $results=$abLocation->getValue($abcResult,"results"); |
|
| 20 | + $results = $abLocation->getValue($abcResult, "results"); |
|
| 21 | 21 | |
| 22 | 22 | Route4Me::simplePrint($results); |
| 23 | 23 | //--------------------------------------------------------- |
@@ -1,26 +1,26 @@ |
||
| 1 | 1 | <?php |
| 2 | - namespace Route4Me; |
|
| 2 | + namespace Route4Me; |
|
| 3 | 3 | |
| 4 | - $vdir=$_SERVER['DOCUMENT_ROOT'].'/route4me/examples/'; |
|
| 5 | - require $vdir.'/../vendor/autoload.php'; |
|
| 4 | + $vdir=$_SERVER['DOCUMENT_ROOT'].'/route4me/examples/'; |
|
| 5 | + require $vdir.'/../vendor/autoload.php'; |
|
| 6 | 6 | |
| 7 | - use Route4Me\Route4Me; |
|
| 7 | + use Route4Me\Route4Me; |
|
| 8 | 8 | |
| 9 | - // Set the api key in the Route4Me class |
|
| 10 | - Route4Me::setApiKey('11111111111111111111111111111111'); |
|
| 9 | + // Set the api key in the Route4Me class |
|
| 10 | + Route4Me::setApiKey('11111111111111111111111111111111'); |
|
| 11 | 11 | |
| 12 | - $ablocation=new AddressBookLocation(); |
|
| 12 | + $ablocation=new AddressBookLocation(); |
|
| 13 | 13 | |
| 14 | - //Example refers to the process of search for routed addresses |
|
| 15 | - //--------------------------------------------------------- |
|
| 16 | - $params= array( |
|
| 14 | + //Example refers to the process of search for routed addresses |
|
| 15 | + //--------------------------------------------------------- |
|
| 16 | + $params= array( |
|
| 17 | 17 | 'display'=> 'routed' |
| 18 | 18 | ); |
| 19 | 19 | |
| 20 | - $abcResult=$ablocation->getAddressBookLocation($params); |
|
| 20 | + $abcResult=$ablocation->getAddressBookLocation($params); |
|
| 21 | 21 | |
| 22 | - $results=$ablocation->getValue($abcResult,"results"); |
|
| 22 | + $results=$ablocation->getValue($abcResult,"results"); |
|
| 23 | 23 | |
| 24 | - Route4Me::simplePrint($results); |
|
| 25 | - //--------------------------------------------------------- |
|
| 24 | + Route4Me::simplePrint($results); |
|
| 25 | + //--------------------------------------------------------- |
|
| 26 | 26 | ?> |
| 27 | 27 | \ No newline at end of file |
@@ -1,7 +1,7 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | 2 | namespace Route4Me; |
| 3 | 3 | |
| 4 | - $vdir=$_SERVER['DOCUMENT_ROOT'].'/route4me/examples/'; |
|
| 4 | + $vdir = $_SERVER['DOCUMENT_ROOT'].'/route4me/examples/'; |
|
| 5 | 5 | require $vdir.'/../vendor/autoload.php'; |
| 6 | 6 | |
| 7 | 7 | use Route4Me\Route4Me; |
@@ -9,17 +9,17 @@ discard block |
||
| 9 | 9 | // Set the api key in the Route4Me class |
| 10 | 10 | Route4Me::setApiKey('11111111111111111111111111111111'); |
| 11 | 11 | |
| 12 | - $ablocation=new AddressBookLocation(); |
|
| 12 | + $ablocation = new AddressBookLocation(); |
|
| 13 | 13 | |
| 14 | 14 | //Example refers to the process of search for routed addresses |
| 15 | 15 | //--------------------------------------------------------- |
| 16 | - $params= array( |
|
| 16 | + $params = array( |
|
| 17 | 17 | 'display'=> 'routed' |
| 18 | 18 | ); |
| 19 | 19 | |
| 20 | - $abcResult=$ablocation->getAddressBookLocation($params); |
|
| 20 | + $abcResult = $ablocation->getAddressBookLocation($params); |
|
| 21 | 21 | |
| 22 | - $results=$ablocation->getValue($abcResult,"results"); |
|
| 22 | + $results = $ablocation->getValue($abcResult, "results"); |
|
| 23 | 23 | |
| 24 | 24 | Route4Me::simplePrint($results); |
| 25 | 25 | //--------------------------------------------------------- |
@@ -3,7 +3,7 @@ |
||
| 3 | 3 | |
| 4 | 4 | $vdir=$_SERVER['DOCUMENT_ROOT'].'/route4me/examples/'; |
| 5 | 5 | |
| 6 | - require $vdir.'/../vendor/autoload.php'; |
|
| 6 | + require $vdir.'/../vendor/autoload.php'; |
|
| 7 | 7 | |
| 8 | 8 | use Route4Me\Route4Me; |
| 9 | 9 | |
@@ -1,7 +1,7 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | 2 | namespace Route4Me; |
| 3 | 3 | |
| 4 | - $vdir=$_SERVER['DOCUMENT_ROOT'].'/route4me/examples/'; |
|
| 4 | + $vdir = $_SERVER['DOCUMENT_ROOT'].'/route4me/examples/'; |
|
| 5 | 5 | |
| 6 | 6 | require $vdir.'/../vendor/autoload.php'; |
| 7 | 7 | |
@@ -10,21 +10,21 @@ discard block |
||
| 10 | 10 | // Set the api key in the Route4Me class |
| 11 | 11 | Route4Me::setApiKey('11111111111111111111111111111111'); |
| 12 | 12 | |
| 13 | - $AdressBookLocationParameters=AddressBookLocation::fromArray(array( |
|
| 14 | - "first_name" => "Test FirstName ".strval(rand(10000,99999)), |
|
| 15 | - "address_1" => "Test Address1 ".strval(rand(10000,99999)), |
|
| 13 | + $AdressBookLocationParameters = AddressBookLocation::fromArray(array( |
|
| 14 | + "first_name" => "Test FirstName ".strval(rand(10000, 99999)), |
|
| 15 | + "address_1" => "Test Address1 ".strval(rand(10000, 99999)), |
|
| 16 | 16 | "cached_lat" => 38.024654, |
| 17 | 17 | "cached_lng" => -77.338814 |
| 18 | 18 | )); |
| 19 | 19 | |
| 20 | - $abLocations=new AddressBookLocation(); |
|
| 20 | + $abLocations = new AddressBookLocation(); |
|
| 21 | 21 | |
| 22 | - $abcResults=$abLocations->addAdressBookLocation($AdressBookLocationParameters); |
|
| 22 | + $abcResults = $abLocations->addAdressBookLocation($AdressBookLocationParameters); |
|
| 23 | 23 | |
| 24 | - $address_id=-1; |
|
| 24 | + $address_id = -1; |
|
| 25 | 25 | if (is_array($abcResults)) { |
| 26 | 26 | if (isset($abcResults["address_id"])) { |
| 27 | - $address_id=$abcResults["address_id"]; |
|
| 27 | + $address_id = $abcResults["address_id"]; |
|
| 28 | 28 | } |
| 29 | 29 | } |
| 30 | 30 | |
@@ -33,9 +33,9 @@ discard block |
||
| 33 | 33 | return; |
| 34 | 34 | } |
| 35 | 35 | echo "Address Book Location with address_id = ".strval($address_id)." was successfully added<br>"; |
| 36 | - $abcResults["first_name"]="Test Firstname Updated"; |
|
| 36 | + $abcResults["first_name"] = "Test Firstname Updated"; |
|
| 37 | 37 | //$abcResults["address_1"]="Test address Updated"; |
| 38 | - $abcResults=$abLocations->updateAdressBookLocation($abcResults); |
|
| 38 | + $abcResults = $abLocations->updateAdressBookLocation($abcResults); |
|
| 39 | 39 | |
| 40 | 40 | Route4Me::simplePrint($abcResults); |
| 41 | 41 | |
@@ -1,18 +1,18 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | - namespace Route4Me; |
|
| 2 | + namespace Route4Me; |
|
| 3 | 3 | |
| 4 | - $vdir=$_SERVER['DOCUMENT_ROOT'].'/route4me/examples/'; |
|
| 5 | - require $vdir.'/../vendor/autoload.php'; |
|
| 4 | + $vdir=$_SERVER['DOCUMENT_ROOT'].'/route4me/examples/'; |
|
| 5 | + require $vdir.'/../vendor/autoload.php'; |
|
| 6 | 6 | |
| 7 | - use Route4Me\Route4Me; |
|
| 7 | + use Route4Me\Route4Me; |
|
| 8 | 8 | |
| 9 | - // Set the api key in the Route4Me class |
|
| 10 | - Route4Me::setApiKey('11111111111111111111111111111111'); |
|
| 9 | + // Set the api key in the Route4Me class |
|
| 10 | + Route4Me::setApiKey('11111111111111111111111111111111'); |
|
| 11 | 11 | |
| 12 | - $ablocation=new AddressBookLocation(); |
|
| 12 | + $ablocation=new AddressBookLocation(); |
|
| 13 | 13 | |
| 14 | - //Example refers to the process of retrieving sepcified fields by containg specified text in any field |
|
| 15 | - //--------------------------------------------------------- |
|
| 14 | + //Example refers to the process of retrieving sepcified fields by containg specified text in any field |
|
| 15 | + //--------------------------------------------------------- |
|
| 16 | 16 | |
| 17 | 17 | $params = array( |
| 18 | 18 | "query" => "David", |
@@ -21,10 +21,10 @@ discard block |
||
| 21 | 21 | "limit" => 20, |
| 22 | 22 | ); |
| 23 | 23 | |
| 24 | - $abcResult=$ablocation->searchRoutedLocation($params); |
|
| 24 | + $abcResult=$ablocation->searchRoutedLocation($params); |
|
| 25 | 25 | |
| 26 | - $results=$ablocation->getValue($abcResult,"results"); |
|
| 26 | + $results=$ablocation->getValue($abcResult,"results"); |
|
| 27 | 27 | |
| 28 | - Route4Me::simplePrint($results); |
|
| 29 | - //--------------------------------------------------------- |
|
| 28 | + Route4Me::simplePrint($results); |
|
| 29 | + //--------------------------------------------------------- |
|
| 30 | 30 | ?> |
| 31 | 31 | \ No newline at end of file |
@@ -1,7 +1,7 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | 2 | namespace Route4Me; |
| 3 | 3 | |
| 4 | - $vdir=$_SERVER['DOCUMENT_ROOT'].'/route4me/examples/'; |
|
| 4 | + $vdir = $_SERVER['DOCUMENT_ROOT'].'/route4me/examples/'; |
|
| 5 | 5 | require $vdir.'/../vendor/autoload.php'; |
| 6 | 6 | |
| 7 | 7 | use Route4Me\Route4Me; |
@@ -9,7 +9,7 @@ discard block |
||
| 9 | 9 | // Set the api key in the Route4Me class |
| 10 | 10 | Route4Me::setApiKey('11111111111111111111111111111111'); |
| 11 | 11 | |
| 12 | - $ablocation=new AddressBookLocation(); |
|
| 12 | + $ablocation = new AddressBookLocation(); |
|
| 13 | 13 | |
| 14 | 14 | //Example refers to the process of retrieving sepcified fields by containg specified text in any field |
| 15 | 15 | //--------------------------------------------------------- |
@@ -21,9 +21,9 @@ discard block |
||
| 21 | 21 | "limit" => 20, |
| 22 | 22 | ); |
| 23 | 23 | |
| 24 | - $abcResult=$ablocation->searchRoutedLocation($params); |
|
| 24 | + $abcResult = $ablocation->searchRoutedLocation($params); |
|
| 25 | 25 | |
| 26 | - $results=$ablocation->getValue($abcResult,"results"); |
|
| 26 | + $results = $ablocation->getValue($abcResult, "results"); |
|
| 27 | 27 | |
| 28 | 28 | Route4Me::simplePrint($results); |
| 29 | 29 | //--------------------------------------------------------- |
@@ -1,24 +1,24 @@ |
||
| 1 | 1 | <?php |
| 2 | - namespace Route4Me; |
|
| 2 | + namespace Route4Me; |
|
| 3 | 3 | |
| 4 | - $vdir=$_SERVER['DOCUMENT_ROOT'].'/route4me/examples/'; |
|
| 5 | - require $vdir.'/../vendor/autoload.php'; |
|
| 4 | + $vdir=$_SERVER['DOCUMENT_ROOT'].'/route4me/examples/'; |
|
| 5 | + require $vdir.'/../vendor/autoload.php'; |
|
| 6 | 6 | |
| 7 | - use Route4Me\Route4Me; |
|
| 7 | + use Route4Me\Route4Me; |
|
| 8 | 8 | |
| 9 | - // Set the api key in the Route4Me class |
|
| 10 | - Route4Me::setApiKey('11111111111111111111111111111111'); |
|
| 9 | + // Set the api key in the Route4Me class |
|
| 10 | + Route4Me::setApiKey('11111111111111111111111111111111'); |
|
| 11 | 11 | |
| 12 | - $ablocation=new AddressBookLocation(); |
|
| 12 | + $ablocation=new AddressBookLocation(); |
|
| 13 | 13 | |
| 14 | - //Example for retrieving Address Book Locations by address_ids |
|
| 15 | - //--------------------------------------------------------- |
|
| 16 | - $ids="4623361,6281217"; |
|
| 14 | + //Example for retrieving Address Book Locations by address_ids |
|
| 15 | + //--------------------------------------------------------- |
|
| 16 | + $ids="4623361,6281217"; |
|
| 17 | 17 | //$ablocation->address_id = $ids; |
| 18 | - $abcResult=$ablocation->getAddressBookLocationsByIds($ids); |
|
| 18 | + $abcResult=$ablocation->getAddressBookLocationsByIds($ids); |
|
| 19 | 19 | |
| 20 | - $results=$ablocation->getValue($abcResult,"results"); |
|
| 20 | + $results=$ablocation->getValue($abcResult,"results"); |
|
| 21 | 21 | |
| 22 | - Route4Me::simplePrint($results); |
|
| 23 | - //--------------------------------------------------------- |
|
| 22 | + Route4Me::simplePrint($results); |
|
| 23 | + //--------------------------------------------------------- |
|
| 24 | 24 | ?> |
| 25 | 25 | \ No newline at end of file |
@@ -1,7 +1,7 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | 2 | namespace Route4Me; |
| 3 | 3 | |
| 4 | - $vdir=$_SERVER['DOCUMENT_ROOT'].'/route4me/examples/'; |
|
| 4 | + $vdir = $_SERVER['DOCUMENT_ROOT'].'/route4me/examples/'; |
|
| 5 | 5 | require $vdir.'/../vendor/autoload.php'; |
| 6 | 6 | |
| 7 | 7 | use Route4Me\Route4Me; |
@@ -9,15 +9,15 @@ discard block |
||
| 9 | 9 | // Set the api key in the Route4Me class |
| 10 | 10 | Route4Me::setApiKey('11111111111111111111111111111111'); |
| 11 | 11 | |
| 12 | - $ablocation=new AddressBookLocation(); |
|
| 12 | + $ablocation = new AddressBookLocation(); |
|
| 13 | 13 | |
| 14 | 14 | //Example for retrieving Address Book Locations by address_ids |
| 15 | 15 | //--------------------------------------------------------- |
| 16 | - $ids="4623361,6281217"; |
|
| 16 | + $ids = "4623361,6281217"; |
|
| 17 | 17 | //$ablocation->address_id = $ids; |
| 18 | - $abcResult=$ablocation->getAddressBookLocationsByIds($ids); |
|
| 18 | + $abcResult = $ablocation->getAddressBookLocationsByIds($ids); |
|
| 19 | 19 | |
| 20 | - $results=$ablocation->getValue($abcResult,"results"); |
|
| 20 | + $results = $ablocation->getValue($abcResult, "results"); |
|
| 21 | 21 | |
| 22 | 22 | Route4Me::simplePrint($results); |
| 23 | 23 | //--------------------------------------------------------- |
@@ -3,7 +3,7 @@ |
||
| 3 | 3 | |
| 4 | 4 | $vdir=$_SERVER['DOCUMENT_ROOT'].'/route4me/examples/'; |
| 5 | 5 | |
| 6 | - require $vdir.'/../vendor/autoload.php'; |
|
| 6 | + require $vdir.'/../vendor/autoload.php'; |
|
| 7 | 7 | |
| 8 | 8 | use Route4Me\Route4Me; |
| 9 | 9 | use Route4Me\Member; |
@@ -1,7 +1,7 @@ |
||
| 1 | 1 | <?php |
| 2 | 2 | namespace Route4Me; |
| 3 | 3 | |
| 4 | - $vdir=$_SERVER['DOCUMENT_ROOT'].'/route4me/examples/'; |
|
| 4 | + $vdir = $_SERVER['DOCUMENT_ROOT'].'/route4me/examples/'; |
|
| 5 | 5 | |
| 6 | 6 | require $vdir.'/../vendor/autoload.php'; |
| 7 | 7 | |
@@ -3,7 +3,7 @@ |
||
| 3 | 3 | |
| 4 | 4 | $vdir=$_SERVER['DOCUMENT_ROOT'].'/route4me/examples/'; |
| 5 | 5 | |
| 6 | - require $vdir.'/../vendor/autoload.php'; |
|
| 6 | + require $vdir.'/../vendor/autoload.php'; |
|
| 7 | 7 | |
| 8 | 8 | use Route4Me\Route4Me; |
| 9 | 9 | use Route4Me\Member; |
@@ -1,7 +1,7 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | 2 | namespace Route4Me; |
| 3 | 3 | |
| 4 | - $vdir=$_SERVER['DOCUMENT_ROOT'].'/route4me/examples/'; |
|
| 4 | + $vdir = $_SERVER['DOCUMENT_ROOT'].'/route4me/examples/'; |
|
| 5 | 5 | |
| 6 | 6 | require $vdir.'/../vendor/autoload.php'; |
| 7 | 7 | |
@@ -13,7 +13,7 @@ discard block |
||
| 13 | 13 | // Set the API key in the Route4Me class |
| 14 | 14 | Route4Me::setApiKey('11111111111111111111111111111111'); |
| 15 | 15 | |
| 16 | - $recordParameters=Member::fromArray(array( |
|
| 16 | + $recordParameters = Member::fromArray(array( |
|
| 17 | 17 | 'member_id' => 777777, |
| 18 | 18 | 'session_guid' => '454563', |
| 19 | 19 | 'device_id' => '54564', |
@@ -3,7 +3,7 @@ |
||
| 3 | 3 | |
| 4 | 4 | $vdir=$_SERVER['DOCUMENT_ROOT'].'/route4me/examples/'; |
| 5 | 5 | |
| 6 | - require $vdir.'/../vendor/autoload.php'; |
|
| 6 | + require $vdir.'/../vendor/autoload.php'; |
|
| 7 | 7 | |
| 8 | 8 | use Route4Me\Route4Me; |
| 9 | 9 | use Route4Me\Member; |
@@ -1,7 +1,7 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | 2 | namespace Route4Me; |
| 3 | 3 | |
| 4 | - $vdir=$_SERVER['DOCUMENT_ROOT'].'/route4me/examples/'; |
|
| 4 | + $vdir = $_SERVER['DOCUMENT_ROOT'].'/route4me/examples/'; |
|
| 5 | 5 | |
| 6 | 6 | require $vdir.'/../vendor/autoload.php'; |
| 7 | 7 | |
@@ -13,7 +13,7 @@ discard block |
||
| 13 | 13 | // Set the api key in the Route4me class |
| 14 | 14 | Route4Me::setApiKey('11111111111111111111111111111111'); |
| 15 | 15 | |
| 16 | - $params = Member::fromArray(array ( |
|
| 16 | + $params = Member::fromArray(array( |
|
| 17 | 17 | "member_id"=> 220461, |
| 18 | 18 | "member_phone"=> "555-777-888" |
| 19 | 19 | )); |
@@ -3,7 +3,7 @@ |
||
| 3 | 3 | |
| 4 | 4 | $vdir=$_SERVER['DOCUMENT_ROOT'].'/route4me/examples/'; |
| 5 | 5 | |
| 6 | - require $vdir.'/../vendor/autoload.php'; |
|
| 6 | + require $vdir.'/../vendor/autoload.php'; |
|
| 7 | 7 | |
| 8 | 8 | use Route4Me\Route4Me; |
| 9 | 9 | use Route4Me\Member; |
@@ -1,7 +1,7 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | 2 | namespace Route4Me; |
| 3 | 3 | |
| 4 | - $vdir=$_SERVER['DOCUMENT_ROOT'].'/route4me/examples/'; |
|
| 4 | + $vdir = $_SERVER['DOCUMENT_ROOT'].'/route4me/examples/'; |
|
| 5 | 5 | |
| 6 | 6 | require $vdir.'/../vendor/autoload.php'; |
| 7 | 7 | |
@@ -13,7 +13,7 @@ discard block |
||
| 13 | 13 | // Set the api key in the Route4me class |
| 14 | 14 | Route4Me::setApiKey('11111111111111111111111111111111'); |
| 15 | 15 | |
| 16 | - $params = Member::fromArray(array ( |
|
| 16 | + $params = Member::fromArray(array( |
|
| 17 | 17 | "member_id"=> 147824 |
| 18 | 18 | )); |
| 19 | 19 | |