PHP code example of adnane / laravel-qibla
1. Go to this page and download the library: Download adnane/laravel-qibla 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/ */
adnane / laravel-qibla example snippets
'providers' => [
..
'Adnane\Qibla\QiblaServiceProvider',
],
use Adnane\Qibla\Qibla;
// get Qibla direction based on user location
echo Qibla::getDirection();
// As you can specify a longitude & latitude to calculate the Qibla direction from
echo Qibla::getDirection($longitude , $latitude);
config\app.php