Get Latitude And Longitude in Session With Laravel and Set Default Value ?
CodePudding user response:
try this
if (Session::get('lat') && Session::get('longi') != null){
$s_lat=Session::get('lat');
$s_longi=Session::get('longi');
$array=[$s_lat,$s_longi,$s_lat];
}
else{
$array=['10','0']; //default lat long
}