Welcome Guest, Not a member yet? Register   Sign In
Pinpoint location with CI on Google Maps
#4

[eluser]veledrom[/eluser]
Hi BIOSTALL,

Would you show me where I have to do changes in order not to do full zoom because map my nose is toughing the gound? 50% is enough for me.

Also what is the difference between yours and this one : http://codeigniter.com/wiki/Google_Maps_API_V3_Library

Thanks


Code:
class Map extends CI_Controller {
function __construct()
{
  parent::__construct();
  
}

function index()
{
  // Load the library
  $this->load->library('googlemaps');



  // Initialize the map, passing through any parameters
  //$config['center'] = '1600 Amphitheatre Parkway in Mountain View, Santa Clara County, California';
  $config['zoom'] = "auto";

  $this->googlemaps->initialize($config);
  // Get the co-ordinates from the database using our model

  
  // Loop through the coordinates we obtained above and add them to the map


  $marker = array();
  $marker['position'] = '51.52296408,-0.155051266';
  $this->googlemaps->add_marker($marker);


  // Create the map
  $data = array();
  
  $data['map'] = $this->googlemaps->create_map();
  // Load our view, passing through the map data
  
  //echo "<pre>";print_r($data);exit;
  
  $this->load->view('map_view', $data);
  
  
}
}


Messages In This Thread
Pinpoint location with CI on Google Maps - by El Forum - 06-01-2012, 07:35 AM
Pinpoint location with CI on Google Maps - by El Forum - 06-01-2012, 07:52 AM
Pinpoint location with CI on Google Maps - by El Forum - 06-01-2012, 08:31 AM
Pinpoint location with CI on Google Maps - by El Forum - 06-01-2012, 08:44 AM
Pinpoint location with CI on Google Maps - by El Forum - 06-01-2012, 09:08 AM



Theme © iAndrew 2016 - Forum software by © MyBB