@@ -1,7 +1,7 @@ |
||
| 1 | 1 | <?php |
| 2 | 2 | /** |
| 3 | - * Map field to point for pois langitude and longitude positioning |
|
| 4 | - */ |
|
| 3 | + * Map field to point for pois langitude and longitude positioning |
|
| 4 | + */ |
|
| 5 | 5 | class MapField extends DatalessField { |
| 6 | 6 | |
| 7 | 7 | /** |
@@ -1,12 +1,12 @@ |
||
| 1 | 1 | <?php |
| 2 | 2 | /** |
| 3 | - * Defines the interface for a mappable DataObject. Implementors of this interface |
|
| 4 | - * must define the following functions in order to work with the {@link GoogleMapUtil} |
|
| 5 | - * helper class. |
|
| 6 | - * |
|
| 7 | - * @author Uncle Cheese |
|
| 8 | - * @package mappable |
|
| 9 | - */ |
|
| 3 | + * Defines the interface for a mappable DataObject. Implementors of this interface |
|
| 4 | + * must define the following functions in order to work with the {@link GoogleMapUtil} |
|
| 5 | + * helper class. |
|
| 6 | + * |
|
| 7 | + * @author Uncle Cheese |
|
| 8 | + * @package mappable |
|
| 9 | + */ |
|
| 10 | 10 | interface Mappable { |
| 11 | 11 | |
| 12 | 12 | /** |
@@ -397,10 +397,10 @@ |
||
| 397 | 397 | } |
| 398 | 398 | |
| 399 | 399 | /** |
| 400 | - * Set the center of the gmap |
|
| 401 | - * |
|
| 402 | - * @return MapAPI This same object, in order to enable chaining of methods |
|
| 403 | - **/ |
|
| 400 | + * Set the center of the gmap |
|
| 401 | + * |
|
| 402 | + * @return MapAPI This same object, in order to enable chaining of methods |
|
| 403 | + **/ |
|
| 404 | 404 | public function setLatLongCenter($center) { |
| 405 | 405 | $this->latLongCenter = $center; |
| 406 | 406 | return $this; |
@@ -80,7 +80,7 @@ |
||
| 80 | 80 | } |
| 81 | 81 | |
| 82 | 82 | //https://maps.googleapis.com/maps/api/staticmap?center=Berkeley,CA&zoom=14&size=400x400&key=YOUR_API_KEY |
| 83 | - //maps.googleapis.com/maps/api/staticmap'; |
|
| 83 | + //maps.googleapis.com/maps/api/staticmap'; |
|
| 84 | 84 | |
| 85 | 85 | $apiurl = Config::inst()->get('MappableData', 'staticmap_api_url'); |
| 86 | 86 | |
@@ -25,11 +25,11 @@ |
||
| 25 | 25 | |
| 26 | 26 | public function test_set_api_key_host_array() { |
| 27 | 27 | $url = Director::absoluteBaseURL(); |
| 28 | - // remove http and https |
|
| 29 | - $url = str_replace('http://', '', $url); |
|
| 30 | - $url = str_replace('https://', '', $url); |
|
| 31 | - $parts = explode('/', $url); |
|
| 32 | - $host = $parts[0]; |
|
| 28 | + // remove http and https |
|
| 29 | + $url = str_replace('http://', '', $url); |
|
| 30 | + $url = str_replace('https://', '', $url); |
|
| 31 | + $parts = explode('/', $url); |
|
| 32 | + $host = $parts[0]; |
|
| 33 | 33 | $key = array($host => 'PRETENDAPIKEY'); |
| 34 | 34 | MapUtil::set_api_key($key); |
| 35 | 35 | $html = $this->htmlForMap(); |