Login   Register  
PHP Classes
elePHPant
Icontem

File: example1.php

Recommend this page to a friend!
Stumble It! Stumble It! Bookmark in del.icio.us Bookmark in del.icio.us
  Classes of Sven Weih  >  N/X API to Google Maps  >  example1.php  >  Download  
File: example1.php
Role: Example script
Content type: text/plain
Description: Example-file
Class: N/X API to Google Maps
Present world maps with Google Maps API
Author: By
Last change:
Date: 2006-09-05 13:00
Size: 831 bytes
 

Contents

Class file image Download
<html>
<?php
require "nxgooglemapsapi.php";


$api = new NXGoogleMapsAPI();

// setup the visual design of the control
$api->setWidth(800);
$api->setHeight(600);
$api->setZoomFactor(16);
$api->addControl(GLargeMapControl);
$api->addControl(GMapTypeControl);
$api->addControl(GOverviewMapControl);

// add an address. the address is geocoded in the webbrowser, not by the server!
$api->addAddress("10 market st, san francisco""Market St<br>This is the info for this point"true);
$api->addAddress("10 california st, san francisco""California St<br>This is the info for this point"false);


?>
<head>

<?php echo $api->getHeadCode(); ?>

</head>

<body onLoad="<?php echo $api->getOnLoadCode(); ?>">

<h1> Adding Addresses to the map </h1>

<?php echo $api->getBodyCode(); ?>

</body>
</html>