PHP code example of salmanbe / mapquest

1. Go to this page and download the library: Download salmanbe/mapquest library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

salmanbe / mapquest example snippets


Salmanbe\MapQuest\MapQuestServiceProvider::class,

'MapQuest' => Salmanbe\MapQuest\MapQuest::class,

'map_quest_url' => env('MAP_QUEST_URL', ''),
'map_quest_key' => env('MAP_QUEST_KEY', ''),

MAP_QUEST_URL=https://www.mapquestapi.com/geocoding/v1/address
MAP_QUEST_KEY=your_mapquest_api_key

$map = new MapQuest();

$map->set($address);

echo $map->latitude();

echo $map->longitude();

echo $map->coordinates();

echo $map->status();