mercredi 7 novembre 2018

Retrieving addresses from DB and using those in Google Map API

I m trying to retrieve addresses from DB and pass it to google map api. I am using this "bradcornford" api right now. But I couldn't figure it out very well.

In the DB table I have, lots of address and I want to display all in google map with a marker. For this: I tried the code below. But no effects:

public function index()
{
    $address = \DB::table('allestates')
        ->where("address")
        ->get();

    Mapper::map();

    return view('welcome', compact('map', 'address'));
}

and my view:

<div style="width: 500px; height: 500px">

    {!! Mapper::render() !!}

</div>



via Chebli Mohamed

Aucun commentaire:

Enregistrer un commentaire