From 4f81e9399051cc90ccddeb69b785d7422a28a1ff Mon Sep 17 00:00:00 2001 From: Comment Date: Wed, 8 May 2013 22:59:04 +0100 Subject: initial commit --- config.php | 21 + fixTable.php | 15 + httpexists-proxy.php | 20 + img/_notes/dwsync.xml | 19 + img/icon_accessible_parking.png | Bin 0 -> 3311 bytes img/icon_accessible_toilet.png | Bin 0 -> 3425 bytes img/icon_entrance.png | Bin 0 -> 3349 bytes img/icon_loop.png | Bin 0 -> 3331 bytes img/icon_parking.png | Bin 0 -> 3218 bytes img/icon_ramp.png | Bin 0 -> 3374 bytes img/map-look-icon.gif | Bin 0 -> 9271 bytes img/map.jpg | Bin 0 -> 157723 bytes img/marker_accessible_parking.png | Bin 0 -> 3798 bytes img/marker_accessible_toilet.png | Bin 0 -> 4010 bytes img/marker_entrance.png | Bin 0 -> 3684 bytes img/marker_loop.png | Bin 0 -> 3832 bytes img/marker_parking.png | Bin 0 -> 3571 bytes img/marker_ramp.png | Bin 0 -> 3914 bytes img/marker_shadow.png | Bin 0 -> 765 bytes img/vanilla-test-image.jpg | Bin 0 -> 8030 bytes index.php | 184 ++++ infobubble.js | 1775 +++++++++++++++++++++++++++++++++++++ loadTable.php | 30 + map.js | 682 ++++++++++++++ map.php | 116 +++ map_prepare.php | 19 + mapedit.php | 26 + maps-extra.js | 165 ++++ photos/1.jpg | Bin 0 -> 136842 bytes photos/12.jpg | Bin 0 -> 174046 bytes photos/124.jpg | Bin 0 -> 169965 bytes photos/13.jpg | Bin 0 -> 160630 bytes photos/14.jpg | Bin 0 -> 177614 bytes photos/15.jpg | Bin 0 -> 153752 bytes photos/16.jpg | Bin 0 -> 153853 bytes photos/17.jpg | Bin 0 -> 155486 bytes photos/18.jpg | Bin 0 -> 158791 bytes photos/181.jpg | Bin 0 -> 177321 bytes photos/19.jpg | Bin 0 -> 141372 bytes photos/194.jpg | Bin 0 -> 124415 bytes photos/198.jpg | Bin 0 -> 94426 bytes photos/199.jpg | Bin 0 -> 147090 bytes photos/200.jpg | Bin 0 -> 108962 bytes photos/211.jpg | Bin 0 -> 134307 bytes photos/22.jpg | Bin 0 -> 158279 bytes photos/23.jpg | Bin 0 -> 171454 bytes photos/233.jpg | Bin 0 -> 82294 bytes photos/243.jpg | Bin 0 -> 154957 bytes photos/246.jpg | Bin 0 -> 124825 bytes photos/249.jpg | Bin 0 -> 113689 bytes photos/250.jpg | Bin 0 -> 118309 bytes photos/253.jpg | Bin 0 -> 169789 bytes photos/254.jpg | Bin 0 -> 134468 bytes photos/32.jpg | Bin 0 -> 213867 bytes photos/40.jpg | Bin 0 -> 135515 bytes photos/54.jpg | Bin 0 -> 119346 bytes photos/55.jpg | Bin 0 -> 100414 bytes photos/56.jpg | Bin 0 -> 149654 bytes photos/57.jpg | Bin 0 -> 144272 bytes photos/58.jpg | Bin 0 -> 127977 bytes photos/59.jpg | Bin 0 -> 132663 bytes photos/61.jpg | Bin 0 -> 198761 bytes photos/67.jpg | Bin 0 -> 129908 bytes photos/68.jpg | Bin 0 -> 173323 bytes photos/7.jpg | Bin 0 -> 147163 bytes photos/70.jpg | Bin 0 -> 107314 bytes photos/71.jpg | Bin 0 -> 168932 bytes photos/73.jpg | Bin 0 -> 156843 bytes photos/74.jpg | Bin 0 -> 208427 bytes photos/75.jpg | Bin 0 -> 146605 bytes photos/8.jpg | Bin 0 -> 121366 bytes photos/81.jpg | Bin 0 -> 135385 bytes photos/82.jpg | Bin 0 -> 116536 bytes photos/83.jpg | Bin 0 -> 177139 bytes photos/9.jpg | Bin 0 -> 153636 bytes photos/_notes/dwsync.xml | 50 ++ photos/small/1.jpg | Bin 0 -> 17975 bytes photos/small/12.jpg | Bin 0 -> 23944 bytes photos/small/124.jpg | Bin 0 -> 22371 bytes photos/small/13.jpg | Bin 0 -> 18394 bytes photos/small/14.jpg | Bin 0 -> 20944 bytes photos/small/15.jpg | Bin 0 -> 18944 bytes photos/small/16.jpg | Bin 0 -> 18581 bytes photos/small/17.jpg | Bin 0 -> 18494 bytes photos/small/18.jpg | Bin 0 -> 19807 bytes photos/small/181.jpg | Bin 0 -> 23165 bytes photos/small/19.jpg | Bin 0 -> 18724 bytes photos/small/194.jpg | Bin 0 -> 17031 bytes photos/small/198.jpg | Bin 0 -> 13086 bytes photos/small/199.jpg | Bin 0 -> 19141 bytes photos/small/200.jpg | Bin 0 -> 14277 bytes photos/small/211.jpg | Bin 0 -> 18160 bytes photos/small/22.jpg | Bin 0 -> 20617 bytes photos/small/23.jpg | Bin 0 -> 23067 bytes photos/small/233.jpg | Bin 0 -> 12337 bytes photos/small/243.jpg | Bin 0 -> 22131 bytes photos/small/246.jpg | Bin 0 -> 15444 bytes photos/small/249.jpg | Bin 0 -> 14776 bytes photos/small/250.jpg | Bin 0 -> 14624 bytes photos/small/253.jpg | Bin 0 -> 20911 bytes photos/small/254.jpg | Bin 0 -> 17887 bytes photos/small/32.jpg | Bin 0 -> 21866 bytes photos/small/40.jpg | Bin 0 -> 18725 bytes photos/small/54.jpg | Bin 0 -> 15704 bytes photos/small/55.jpg | Bin 0 -> 14439 bytes photos/small/56.jpg | Bin 0 -> 19683 bytes photos/small/57.jpg | Bin 0 -> 19592 bytes photos/small/58.jpg | Bin 0 -> 19233 bytes photos/small/59.jpg | Bin 0 -> 18907 bytes photos/small/61.jpg | Bin 0 -> 21987 bytes photos/small/67.jpg | Bin 0 -> 16520 bytes photos/small/68.jpg | Bin 0 -> 22080 bytes photos/small/7.jpg | Bin 0 -> 19929 bytes photos/small/70.jpg | Bin 0 -> 15656 bytes photos/small/71.jpg | Bin 0 -> 24992 bytes photos/small/73.jpg | Bin 0 -> 19684 bytes photos/small/74.jpg | Bin 0 -> 24497 bytes photos/small/75.jpg | Bin 0 -> 19608 bytes photos/small/8.jpg | Bin 0 -> 14443 bytes photos/small/81.jpg | Bin 0 -> 16902 bytes photos/small/82.jpg | Bin 0 -> 13788 bytes photos/small/83.jpg | Bin 0 -> 22166 bytes photos/small/9.jpg | Bin 0 -> 17914 bytes photos/small/_notes/dwsync.xml | 50 ++ photos/thumbs/1.jpg | Bin 0 -> 10889 bytes photos/thumbs/12.jpg | Bin 0 -> 14162 bytes photos/thumbs/124.jpg | Bin 0 -> 13520 bytes photos/thumbs/13.jpg | Bin 0 -> 12067 bytes photos/thumbs/14.jpg | Bin 0 -> 13857 bytes photos/thumbs/15.jpg | Bin 0 -> 12529 bytes photos/thumbs/16.jpg | Bin 0 -> 12415 bytes photos/thumbs/17.jpg | Bin 0 -> 12458 bytes photos/thumbs/18.jpg | Bin 0 -> 13759 bytes photos/thumbs/181.jpg | Bin 0 -> 13997 bytes photos/thumbs/19.jpg | Bin 0 -> 11458 bytes photos/thumbs/194.jpg | Bin 0 -> 10438 bytes photos/thumbs/198.jpg | Bin 0 -> 9032 bytes photos/thumbs/199.jpg | Bin 0 -> 12236 bytes photos/thumbs/200.jpg | Bin 0 -> 9216 bytes photos/thumbs/211.jpg | Bin 0 -> 12047 bytes photos/thumbs/22.jpg | Bin 0 -> 13423 bytes photos/thumbs/23.jpg | Bin 0 -> 13849 bytes photos/thumbs/233.jpg | Bin 0 -> 7882 bytes photos/thumbs/243.jpg | Bin 0 -> 14361 bytes photos/thumbs/246.jpg | Bin 0 -> 10861 bytes photos/thumbs/249.jpg | Bin 0 -> 10164 bytes photos/thumbs/250.jpg | Bin 0 -> 9803 bytes photos/thumbs/253.jpg | Bin 0 -> 14201 bytes photos/thumbs/254.jpg | Bin 0 -> 12827 bytes photos/thumbs/32.jpg | Bin 0 -> 14749 bytes photos/thumbs/40.jpg | Bin 0 -> 12703 bytes photos/thumbs/54.jpg | Bin 0 -> 10846 bytes photos/thumbs/55.jpg | Bin 0 -> 9190 bytes photos/thumbs/56.jpg | Bin 0 -> 12245 bytes photos/thumbs/57.jpg | Bin 0 -> 11784 bytes photos/thumbs/58.jpg | Bin 0 -> 12064 bytes photos/thumbs/59.jpg | Bin 0 -> 11362 bytes photos/thumbs/61.jpg | Bin 0 -> 14450 bytes photos/thumbs/67.jpg | Bin 0 -> 11376 bytes photos/thumbs/68.jpg | Bin 0 -> 13655 bytes photos/thumbs/7.jpg | Bin 0 -> 13500 bytes photos/thumbs/70.jpg | Bin 0 -> 9941 bytes photos/thumbs/71.jpg | Bin 0 -> 14600 bytes photos/thumbs/73.jpg | Bin 0 -> 13561 bytes photos/thumbs/74.jpg | Bin 0 -> 16768 bytes photos/thumbs/75.jpg | Bin 0 -> 13702 bytes photos/thumbs/8.jpg | Bin 0 -> 9913 bytes photos/thumbs/81.jpg | Bin 0 -> 11474 bytes photos/thumbs/82.jpg | Bin 0 -> 8381 bytes photos/thumbs/83.jpg | Bin 0 -> 13315 bytes photos/thumbs/9.jpg | Bin 0 -> 12035 bytes photos/thumbs/_notes/dwsync.xml | 50 ++ setMarkerPos.php | 17 + styles-working.css | 83 ++ tableKML.php | 32 + 175 files changed, 3354 insertions(+) create mode 100755 config.php create mode 100755 fixTable.php create mode 100755 httpexists-proxy.php create mode 100755 img/_notes/dwsync.xml create mode 100755 img/icon_accessible_parking.png create mode 100755 img/icon_accessible_toilet.png create mode 100755 img/icon_entrance.png create mode 100755 img/icon_loop.png create mode 100755 img/icon_parking.png create mode 100755 img/icon_ramp.png create mode 100755 img/map-look-icon.gif create mode 100755 img/map.jpg create mode 100755 img/marker_accessible_parking.png create mode 100755 img/marker_accessible_toilet.png create mode 100755 img/marker_entrance.png create mode 100755 img/marker_loop.png create mode 100755 img/marker_parking.png create mode 100755 img/marker_ramp.png create mode 100755 img/marker_shadow.png create mode 100755 img/vanilla-test-image.jpg create mode 100755 index.php create mode 100755 infobubble.js create mode 100755 loadTable.php create mode 100755 map.js create mode 100755 map.php create mode 100755 map_prepare.php create mode 100755 mapedit.php create mode 100755 maps-extra.js create mode 100755 photos/1.jpg create mode 100755 photos/12.jpg create mode 100755 photos/124.jpg create mode 100755 photos/13.jpg create mode 100755 photos/14.jpg create mode 100755 photos/15.jpg create mode 100755 photos/16.jpg create mode 100755 photos/17.jpg create mode 100755 photos/18.jpg create mode 100755 photos/181.jpg create mode 100755 photos/19.jpg create mode 100755 photos/194.jpg create mode 100755 photos/198.jpg create mode 100755 photos/199.jpg create mode 100755 photos/200.jpg create mode 100755 photos/211.jpg create mode 100755 photos/22.jpg create mode 100755 photos/23.jpg create mode 100755 photos/233.jpg create mode 100755 photos/243.jpg create mode 100755 photos/246.jpg create mode 100755 photos/249.jpg create mode 100755 photos/250.jpg create mode 100755 photos/253.jpg create mode 100755 photos/254.jpg create mode 100755 photos/32.jpg create mode 100755 photos/40.jpg create mode 100755 photos/54.jpg create mode 100755 photos/55.jpg create mode 100755 photos/56.jpg create mode 100755 photos/57.jpg create mode 100755 photos/58.jpg create mode 100755 photos/59.jpg create mode 100755 photos/61.jpg create mode 100755 photos/67.jpg create mode 100755 photos/68.jpg create mode 100755 photos/7.jpg create mode 100755 photos/70.jpg create mode 100755 photos/71.jpg create mode 100755 photos/73.jpg create mode 100755 photos/74.jpg create mode 100755 photos/75.jpg create mode 100755 photos/8.jpg create mode 100755 photos/81.jpg create mode 100755 photos/82.jpg create mode 100755 photos/83.jpg create mode 100755 photos/9.jpg create mode 100755 photos/_notes/dwsync.xml create mode 100755 photos/small/1.jpg create mode 100755 photos/small/12.jpg create mode 100755 photos/small/124.jpg create mode 100755 photos/small/13.jpg create mode 100755 photos/small/14.jpg create mode 100755 photos/small/15.jpg create mode 100755 photos/small/16.jpg create mode 100755 photos/small/17.jpg create mode 100755 photos/small/18.jpg create mode 100755 photos/small/181.jpg create mode 100755 photos/small/19.jpg create mode 100755 photos/small/194.jpg create mode 100755 photos/small/198.jpg create mode 100755 photos/small/199.jpg create mode 100755 photos/small/200.jpg create mode 100755 photos/small/211.jpg create mode 100755 photos/small/22.jpg create mode 100755 photos/small/23.jpg create mode 100755 photos/small/233.jpg create mode 100755 photos/small/243.jpg create mode 100755 photos/small/246.jpg create mode 100755 photos/small/249.jpg create mode 100755 photos/small/250.jpg create mode 100755 photos/small/253.jpg create mode 100755 photos/small/254.jpg create mode 100755 photos/small/32.jpg create mode 100755 photos/small/40.jpg create mode 100755 photos/small/54.jpg create mode 100755 photos/small/55.jpg create mode 100755 photos/small/56.jpg create mode 100755 photos/small/57.jpg create mode 100755 photos/small/58.jpg create mode 100755 photos/small/59.jpg create mode 100755 photos/small/61.jpg create mode 100755 photos/small/67.jpg create mode 100755 photos/small/68.jpg create mode 100755 photos/small/7.jpg create mode 100755 photos/small/70.jpg create mode 100755 photos/small/71.jpg create mode 100755 photos/small/73.jpg create mode 100755 photos/small/74.jpg create mode 100755 photos/small/75.jpg create mode 100755 photos/small/8.jpg create mode 100755 photos/small/81.jpg create mode 100755 photos/small/82.jpg create mode 100755 photos/small/83.jpg create mode 100755 photos/small/9.jpg create mode 100755 photos/small/_notes/dwsync.xml create mode 100755 photos/thumbs/1.jpg create mode 100755 photos/thumbs/12.jpg create mode 100755 photos/thumbs/124.jpg create mode 100755 photos/thumbs/13.jpg create mode 100755 photos/thumbs/14.jpg create mode 100755 photos/thumbs/15.jpg create mode 100755 photos/thumbs/16.jpg create mode 100755 photos/thumbs/17.jpg create mode 100755 photos/thumbs/18.jpg create mode 100755 photos/thumbs/181.jpg create mode 100755 photos/thumbs/19.jpg create mode 100755 photos/thumbs/194.jpg create mode 100755 photos/thumbs/198.jpg create mode 100755 photos/thumbs/199.jpg create mode 100755 photos/thumbs/200.jpg create mode 100755 photos/thumbs/211.jpg create mode 100755 photos/thumbs/22.jpg create mode 100755 photos/thumbs/23.jpg create mode 100755 photos/thumbs/233.jpg create mode 100755 photos/thumbs/243.jpg create mode 100755 photos/thumbs/246.jpg create mode 100755 photos/thumbs/249.jpg create mode 100755 photos/thumbs/250.jpg create mode 100755 photos/thumbs/253.jpg create mode 100755 photos/thumbs/254.jpg create mode 100755 photos/thumbs/32.jpg create mode 100755 photos/thumbs/40.jpg create mode 100755 photos/thumbs/54.jpg create mode 100755 photos/thumbs/55.jpg create mode 100755 photos/thumbs/56.jpg create mode 100755 photos/thumbs/57.jpg create mode 100755 photos/thumbs/58.jpg create mode 100755 photos/thumbs/59.jpg create mode 100755 photos/thumbs/61.jpg create mode 100755 photos/thumbs/67.jpg create mode 100755 photos/thumbs/68.jpg create mode 100755 photos/thumbs/7.jpg create mode 100755 photos/thumbs/70.jpg create mode 100755 photos/thumbs/71.jpg create mode 100755 photos/thumbs/73.jpg create mode 100755 photos/thumbs/74.jpg create mode 100755 photos/thumbs/75.jpg create mode 100755 photos/thumbs/8.jpg create mode 100755 photos/thumbs/81.jpg create mode 100755 photos/thumbs/82.jpg create mode 100755 photos/thumbs/83.jpg create mode 100755 photos/thumbs/9.jpg create mode 100755 photos/thumbs/_notes/dwsync.xml create mode 100755 setMarkerPos.php create mode 100755 styles-working.css create mode 100644 tableKML.php diff --git a/config.php b/config.php new file mode 100755 index 0000000..b0fe6ed --- /dev/null +++ b/config.php @@ -0,0 +1,21 @@ + \ No newline at end of file diff --git a/fixTable.php b/fixTable.php new file mode 100755 index 0000000..c726ad9 --- /dev/null +++ b/fixTable.php @@ -0,0 +1,15 @@ +"; +echo mysql_query($query); +mysql_close(); + +?> diff --git a/httpexists-proxy.php b/httpexists-proxy.php new file mode 100755 index 0000000..adc4df4 --- /dev/null +++ b/httpexists-proxy.php @@ -0,0 +1,20 @@ + \ No newline at end of file diff --git a/img/_notes/dwsync.xml b/img/_notes/dwsync.xml new file mode 100755 index 0000000..644d085 --- /dev/null +++ b/img/_notes/dwsync.xml @@ -0,0 +1,19 @@ + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/img/icon_accessible_parking.png b/img/icon_accessible_parking.png new file mode 100755 index 0000000..3910870 Binary files /dev/null and b/img/icon_accessible_parking.png differ diff --git a/img/icon_accessible_toilet.png b/img/icon_accessible_toilet.png new file mode 100755 index 0000000..5660146 Binary files /dev/null and b/img/icon_accessible_toilet.png differ diff --git a/img/icon_entrance.png b/img/icon_entrance.png new file mode 100755 index 0000000..1dfbcae Binary files /dev/null and b/img/icon_entrance.png differ diff --git a/img/icon_loop.png b/img/icon_loop.png new file mode 100755 index 0000000..51e6bb8 Binary files /dev/null and b/img/icon_loop.png differ diff --git a/img/icon_parking.png b/img/icon_parking.png new file mode 100755 index 0000000..b300fcc Binary files /dev/null and b/img/icon_parking.png differ diff --git a/img/icon_ramp.png b/img/icon_ramp.png new file mode 100755 index 0000000..f308283 Binary files /dev/null and b/img/icon_ramp.png differ diff --git a/img/map-look-icon.gif b/img/map-look-icon.gif new file mode 100755 index 0000000..10b4b7d Binary files /dev/null and b/img/map-look-icon.gif differ diff --git a/img/map.jpg b/img/map.jpg new file mode 100755 index 0000000..7a462f9 Binary files /dev/null and b/img/map.jpg differ diff --git a/img/marker_accessible_parking.png b/img/marker_accessible_parking.png new file mode 100755 index 0000000..1539170 Binary files /dev/null and b/img/marker_accessible_parking.png differ diff --git a/img/marker_accessible_toilet.png b/img/marker_accessible_toilet.png new file mode 100755 index 0000000..326bb26 Binary files /dev/null and b/img/marker_accessible_toilet.png differ diff --git a/img/marker_entrance.png b/img/marker_entrance.png new file mode 100755 index 0000000..3b025fd Binary files /dev/null and b/img/marker_entrance.png differ diff --git a/img/marker_loop.png b/img/marker_loop.png new file mode 100755 index 0000000..9ab312c Binary files /dev/null and b/img/marker_loop.png differ diff --git a/img/marker_parking.png b/img/marker_parking.png new file mode 100755 index 0000000..6367918 Binary files /dev/null and b/img/marker_parking.png differ diff --git a/img/marker_ramp.png b/img/marker_ramp.png new file mode 100755 index 0000000..244125f Binary files /dev/null and b/img/marker_ramp.png differ diff --git a/img/marker_shadow.png b/img/marker_shadow.png new file mode 100755 index 0000000..de0463b Binary files /dev/null and b/img/marker_shadow.png differ diff --git a/img/vanilla-test-image.jpg b/img/vanilla-test-image.jpg new file mode 100755 index 0000000..3243b9f Binary files /dev/null and b/img/vanilla-test-image.jpg differ diff --git a/index.php b/index.php new file mode 100755 index 0000000..d6e383d --- /dev/null +++ b/index.php @@ -0,0 +1,184 @@ + + + +College Maps : Trinity College Dublin + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+

Trinity College Dublin

+

Skip to main content.

+ +

Core links

+ +
+ +
+
+

College Maps

+ + +
+ +
+ + + +
+
+
+
+
+
+
+ +
+
+
+
+
+
+

Interactive Map

+

Our new searchable interactive college map is a great resource for finding your way around the Trinity campus. Future releases of this website will include building imagery and details. Missing or incorrect information can be reported by emailing webdes@tcd.ie.

+
+
+

The website also includes information on college facilities along with directions to Trinity and printable versions of the maps.

+
+
+
+ + + + + + +
+
+
+
+
+
+
+

Last updated 19 Feb 2009 by College Maps.

+
+ +
+ + diff --git a/infobubble.js b/infobubble.js new file mode 100755 index 0000000..06c3744 --- /dev/null +++ b/infobubble.js @@ -0,0 +1,1775 @@ +// ==ClosureCompiler== +// @compilation_level ADVANCED_OPTIMIZATIONS +// @externs_url http://closure-compiler.googlecode.com/svn/trunk/contrib/externs/maps/google_maps_api_v3.js +// ==/ClosureCompiler== + +/** + * @name CSS3 InfoBubble with tabs for Google Maps API V3 + * @version 0.8 + * @author Luke Mahe + * @fileoverview + * This library is a CSS Infobubble with tabs. It uses css3 rounded corners and + * drop shadows and animations. It also allows tabs + */ + +/* + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + +/** + * A CSS3 InfoBubble v0.8 + * @param {Object.=} opt_options Optional properties to set. + * @extends {google.maps.OverlayView} + * @constructor + */ +function InfoBubble(opt_options) { + this.extend(InfoBubble, google.maps.OverlayView); + this.tabs_ = []; + this.activeTab_ = null; + this.baseZIndex_ = 100; + this.isOpen_ = false; + + var options = opt_options || {}; + + if (options['backgroundColor'] == undefined) { + options['backgroundColor'] = this.BACKGROUND_COLOR_; + } + + if (options['borderColor'] == undefined) { + options['borderColor'] = this.BORDER_COLOR_; + } + + if (options['borderRadius'] == undefined) { + options['borderRadius'] = this.BORDER_RADIUS_; + } + + if (options['borderWidth'] == undefined) { + options['borderWidth'] = this.BORDER_WIDTH_; + } + + if (options['padding'] == undefined) { + options['padding'] = this.PADDING_; + } + + if (options['arrowPosition'] == undefined) { + options['arrowPosition'] = this.ARROW_POSITION_; + } + + if (options['disableAutoPan'] == undefined) { + options['disableAutoPan'] = false; + } + + if (options['disableAnimation'] == undefined) { + options['disableAnimation'] = false; + } + + if (options['minWidth'] == undefined) { + options['minWidth'] = this.MIN_WIDTH_; + } + + if (options['shadowStyle'] == undefined) { + options['shadowStyle'] = this.SHADOW_STYLE_; + } + + if (options['arrowSize'] == undefined) { + options['arrowSize'] = this.ARROW_SIZE_; + } + + if (options['arrowStyle'] == undefined) { + options['arrowStyle'] = this.ARROW_STYLE_; + } + + this.buildDom_(); + + this.setValues(options); +} +window['InfoBubble'] = InfoBubble; + + +/** + * Default arrow size + * @const + * @private + */ +InfoBubble.prototype.ARROW_SIZE_ = 15; + + +/** + * Default arrow style + * @const + * @private + */ +InfoBubble.prototype.ARROW_STYLE_ = 0; + + +/** + * Default shadow style + * @const + * @private + */ +InfoBubble.prototype.SHADOW_STYLE_ = 1; + + +/** + * Default min width + * @const + * @private + */ +InfoBubble.prototype.MIN_WIDTH_ = 50; + + +/** + * Default arrow position + * @const + * @private + */ +InfoBubble.prototype.ARROW_POSITION_ = 50; + + +/** + * Default padding + * @const + * @private + */ +InfoBubble.prototype.PADDING_ = 10; + + +/** + * Default border width + * @const + * @private + */ +InfoBubble.prototype.BORDER_WIDTH_ = 1; + + +/** + * Default border color + * @const + * @private + */ +InfoBubble.prototype.BORDER_COLOR_ = '#ccc'; + + +/** + * Default border radius + * @const + * @private + */ +InfoBubble.prototype.BORDER_RADIUS_ = 10; + + +/** + * Default background color + * @const + * @private + */ +InfoBubble.prototype.BACKGROUND_COLOR_ = '#fff'; + + +/** + * Extends a objects prototype by anothers. + * + * @param {Object} obj1 The object to be extended. + * @param {Object} obj2 The object to extend with. + * @return {Object} The new extended object. + * @ignore + */ +InfoBubble.prototype.extend = function(obj1, obj2) { + return (function(object) { + for (var property in object.prototype) { + this.prototype[property] = object.prototype[property]; + } + return this; + }).apply(obj1, [obj2]); +}; + + +/** + * Builds the InfoBubble dom + * @private + */ +InfoBubble.prototype.buildDom_ = function() { + var bubble = this.bubble_ = document.createElement('DIV'); + bubble.style['position'] = 'absolute'; + bubble.style['zIndex'] = this.baseZIndex_; + + var tabsContainer = this.tabsContainer_ = document.createElement('DIV'); + tabsContainer.style['position'] = 'relative'; + + // Close button + var close = this.close_ = document.createElement('IMG'); + close.style['position'] = 'absolute'; + close.style['width'] = this.px(12); + close.style['height'] = this.px(12); + close.style['border'] = 0; + close.style['zIndex'] = this.baseZIndex_ + 1; + close.style['cursor'] = 'pointer'; + close.src = 'http://maps.gstatic.com/intl/en_us/mapfiles/iw_close.gif'; + + var that = this; + google.maps.event.addDomListener(close, 'click', function() { + that.close(); + google.maps.event.trigger(that, 'closeclick'); + }); + + // Content area + var contentContainer = this.contentContainer_ = document.createElement('DIV'); + contentContainer.style['overflowX'] = 'auto'; + contentContainer.style['overflowY'] = 'auto'; + contentContainer.style['cursor'] = 'default'; + contentContainer.style['clear'] = 'both'; + contentContainer.style['position'] = 'relative'; + + var content = this.content_ = document.createElement('DIV'); + contentContainer.appendChild(content); + + // Arrow + var arrow = this.arrow_ = document.createElement('DIV'); + arrow.style['position'] = 'relative'; + + var arrowOuter = this.arrowOuter_ = document.createElement('DIV'); + var arrowInner = this.arrowInner_ = document.createElement('DIV'); + + var arrowSize = this.getArrowSize_(); + + arrowOuter.style['position'] = arrowInner.style['position'] = 'absolute'; + arrowOuter.style['left'] = arrowInner.style['left'] = '50%'; + arrowOuter.style['height'] = arrowInner.style['height'] = '0'; + arrowOuter.style['width'] = arrowInner.style['width'] = '0'; + arrowOuter.style['marginLeft'] = this.px(-arrowSize); + arrowOuter.style['borderWidth'] = this.px(arrowSize); + arrowOuter.style['borderBottomWidth'] = 0; + + // Shadow + var bubbleShadow = this.bubbleShadow_ = document.createElement('DIV'); + bubbleShadow.style['position'] = 'absolute'; + + // Hide the InfoBubble by default + bubble.style['display'] = bubbleShadow.style['display'] = 'none'; + + bubble.appendChild(this.tabsContainer_); + bubble.appendChild(close); + bubble.appendChild(contentContainer); + arrow.appendChild(arrowOuter); + arrow.appendChild(arrowInner); + bubble.appendChild(arrow); + + var stylesheet = document.createElement('style'); + stylesheet.setAttribute('type', 'text/css'); + + /** + * The animation for the infobubble + * @type {string} + */ + this.animationName_ = '_ibani_' + Math.round(Math.random() * 10000); + + var css = '.' + this.animationName_ + '{-webkit-animation-name:' + + this.animationName_ + ';-webkit-animation-duration:0.5s;' + + '-webkit-animation-iteration-count:1;}' + + '@-webkit-keyframes ' + this.animationName_ + ' {from {' + + '-webkit-transform: scale(0)}50% {-webkit-transform: scale(1.2)}90% ' + + '{-webkit-transform: scale(0.95)}to {-webkit-transform: scale(1)}}'; + + stylesheet.textContent = css; + document.getElementsByTagName('head')[0].appendChild(stylesheet); +}; + + +/** + * Sets the background class name + * + * @param {string} className The class name to set. + */ +InfoBubble.prototype.setBackgroundClassName = function(className) { + this.set('backgroundClassName', className); +}; +InfoBubble.prototype['setBackgroundClassName'] = + InfoBubble.prototype.setBackgroundClassName; + + +/** + * changed MVC callback + */ +InfoBubble.prototype.backgroundClassName_changed = function() { + this.content_.className = this.get('backgroundClassName'); +}; +InfoBubble.prototype['backgroundClassName_changed'] = + InfoBubble.prototype.backgroundClassName_changed; + + +/** + * Sets the class of the tab + * + * @param {string} className the class name to set. + */ +InfoBubble.prototype.setTabClassName = function(className) { + this.set('tabClassName', className); +}; +InfoBubble.prototype['setTabClassName'] = + InfoBubble.prototype.setTabClassName; + + +/** + * tabClassName changed MVC callback + */ +InfoBubble.prototype.tabClassName_changed = function() { + this.updateTabStyles_(); +}; +InfoBubble.prototype['tabClassName_changed'] = + InfoBubble.prototype.tabClassName_changed; + + +/** + * Gets the style of the arrow + * + * @private + * @return {number} The style of the arrow. + */ +InfoBubble.prototype.getArrowStyle_ = function() { + return parseInt(this.get('arrowStyle'), 10) || 0; +}; + + +/** + * Sets the style of the arrow + * + * @param {number} style The style of the arrow. + */ +InfoBubble.prototype.setArrowStyle = function(style) { + this.set('arrowStyle', style); +}; +InfoBubble.prototype['setArrowStyle'] = + InfoBubble.prototype.setArrowStyle; + + +/** + * Arrow style changed MVC callback + */ +InfoBubble.prototype.arrowStyle_changed = function() { + this.arrowSize_changed(); +}; +InfoBubble.prototype['arrowStyle_changed'] = + InfoBubble.prototype.arrowStyle_changed; + + +/** + * Gets the size of the arrow + * + * @private + * @return {number} The size of the arrow. + */ +InfoBubble.prototype.getArrowSize_ = function() { + return parseInt(this.get('arrowSize'), 10) || 0; +}; + + +/** + * Sets the size of the arrow + * + * @param {number} size The size of the arrow. + */ +InfoBubble.prototype.setArrowSize = function(size) { + this.set('arrowSize', size); +}; +InfoBubble.prototype['setArrowSize'] = + InfoBubble.prototype.setArrowSize; + + +/** + * Arrow size changed MVC callback + */ +InfoBubble.prototype.arrowSize_changed = function() { + this.borderWidth_changed(); +}; +InfoBubble.prototype['arrowSize_changed'] = + InfoBubble.prototype.arrowSize_changed; + + +/** + * Set the position of the InfoBubble arrow + * + * @param {number} pos The position to set. + */ +InfoBubble.prototype.setArrowPosition = function(pos) { + this.set('arrowPosition', pos); +}; +InfoBubble.prototype['setArrowPosition'] = + InfoBubble.prototype.setArrowPosition; + + +/** + * Get the position of the InfoBubble arrow + * + * @private + * @return {number} The position.. + */ +InfoBubble.prototype.getArrowPosition_ = function() { + return parseInt(this.get('arrowPosition'), 10) || 0; +}; + + +/** + * arrowPosition changed MVC callback + */ +InfoBubble.prototype.arrowPosition_changed = function() { + var pos = this.getArrowPosition_(); + this.arrowOuter_.style['left'] = this.arrowInner_.style['left'] = pos + '%'; + + this.redraw_(); +}; +InfoBubble.prototype['arrowPosition_changed'] = + InfoBubble.prototype.arrowPosition_changed; + + +/** + * Set the zIndex of the InfoBubble + * + * @param {number} zIndex The zIndex to set. + */ +InfoBubble.prototype.setZIndex = function(zIndex) { + this.set('zIndex', zIndex); +}; +InfoBubble.prototype['setZIndex'] = InfoBubble.prototype.setZIndex; + + +/** + * Get the zIndex of the InfoBubble + * + * @return {number} The zIndex to set. + */ +InfoBubble.prototype.getZIndex = function() { + return parseInt(this.get('zIndex'), 10) || this.baseZIndex_; +}; + + +/** + * zIndex changed MVC callback + */ +InfoBubble.prototype.zIndex_changed = function() { + var zIndex = this.getZIndex(); + + this.bubble_.style['zIndex'] = this.baseZIndex_ = zIndex; + this.close_.style['zIndex'] = zIndex + 1; +}; +InfoBubble.prototype['zIndex_changed'] = InfoBubble.prototype.zIndex_changed; + + +/** + * Set the style of the shadow + * + * @param {number} shadowStyle The style of the shadow. + */ +InfoBubble.prototype.setShadowStyle = function(shadowStyle) { + this.set('shadowStyle', shadowStyle); +}; +InfoBubble.prototype['setShadowStyle'] = InfoBubble.prototype.setShadowStyle; + + +/** + * Get the style of the shadow + * + * @private + * @return {number} The style of the shadow. + */ +InfoBubble.prototype.getShadowStyle_ = function() { + return parseInt(this.get('shadowStyle'), 10) || 0; +}; + + +/** + * shadowStyle changed MVC callback + */ +InfoBubble.prototype.shadowStyle_changed = function() { + var shadowStyle = this.getShadowStyle_(); + + var display = ''; + var shadow = ''; + var backgroundColor = ''; + switch (shadowStyle) { + case 0: + display = 'none'; + break; + case 1: + shadow = '40px 15px 10px rgba(33,33,33,0.3)'; + backgroundColor = 'transparent'; + break; + case 2: + shadow = '0 0 2px rgba(33,33,33,0.3)'; + backgroundColor = 'rgba(33,33,33,0.35)'; + break; + } + this.bubbleShadow_.style['boxShadow'] = + this.bubbleShadow_.style['webkitBoxShadow'] = + this.bubbleShadow_.style['MozBoxShadow'] = shadow; + this.bubbleShadow_.style['backgroundColor'] = backgroundColor; + if (this.isOpen_) { + this.bubbleShadow_.style['display'] = display; + this.draw(); + } +}; +InfoBubble.prototype['shadowStyle_changed'] = + InfoBubble.prototype.shadowStyle_changed; + + +/** + * Show the close button + */ +InfoBubble.prototype.showCloseButton = function() { + this.set('hideCloseButton', false); +}; +InfoBubble.prototype['showCloseButton'] = InfoBubble.prototype.showCloseButton; + + +/** + * Hide the close button + */ +InfoBubble.prototype.hideCloseButton = function() { + this.set('hideCloseButton', true); +}; +InfoBubble.prototype['hideCloseButton'] = InfoBubble.prototype.hideCloseButton; + + +/** + * hideCloseButton changed MVC callback + */ +InfoBubble.prototype.hideCloseButton_changed = function() { + this.close_.style['display'] = this.get('hideCloseButton') ? 'none' : ''; +}; +InfoBubble.prototype['hideCloseButton_changed'] = + InfoBubble.prototype.hideCloseButton_changed; + + +/** + * Set the background color + * + * @param {string} color The color to set. + */ +InfoBubble.prototype.setBackgroundColor = function(color) { + if (color) { + this.set('backgroundColor', color); + } +}; +InfoBubble.prototype['setBackgroundColor'] = + InfoBubble.prototype.setBackgroundColor; + + +/** + * backgroundColor changed MVC callback + */ +InfoBubble.prototype.backgroundColor_changed = function() { + var backgroundColor = this.get('backgroundColor'); + this.contentContainer_.style['backgroundColor'] = backgroundColor; + + this.arrowInner_.style['borderColor'] = backgroundColor + + ' transparent transparent'; + this.updateTabStyles_(); +}; +InfoBubble.prototype['backgroundColor_changed'] = + InfoBubble.prototype.backgroundColor_changed; + + +/** + * Set the border color + * + * @param {string} color The border color. + */ +InfoBubble.prototype.setBorderColor = function(color) { + if (color) { + this.set('borderColor', color); + } +}; +InfoBubble.prototype['setBorderColor'] = InfoBubble.prototype.setBorderColor; + + +/** + * borderColor changed MVC callback + */ +InfoBubble.prototype.borderColor_changed = function() { + var borderColor = this.get('borderColor'); + + var contentContainer = this.contentContainer_; + var arrowOuter = this.arrowOuter_; + contentContainer.style['borderColor'] = borderColor; + + arrowOuter.style['borderColor'] = borderColor + + ' transparent transparent'; + + contentContainer.style['borderStyle'] = + arrowOuter.style['borderStyle'] = + this.arrowInner_.style['borderStyle'] = 'solid'; + + this.updateTabStyles_(); +}; +InfoBubble.prototype['borderColor_changed'] = + InfoBubble.prototype.borderColor_changed; + + +/** + * Set the radius of the border + * + * @param {number} radius The radius of the border. + */ +InfoBubble.prototype.setBorderRadius = function(radius) { + this.set('borderRadius', radius); +}; +InfoBubble.prototype['setBorderRadius'] = InfoBubble.prototype.setBorderRadius; + + +/** + * Get the radius of the border + * + * @private + * @return {number} The radius of the border. + */ +InfoBubble.prototype.getBorderRadius_ = function() { + return parseInt(this.get('borderRadius'), 10) || 0; +}; + + +/** + * borderRadius changed MVC callback + */ +InfoBubble.prototype.borderRadius_changed = function() { + var borderRadius = this.getBorderRadius_(); + var borderWidth = this.getBorderWidth_(); + + this.contentContainer_.style['borderRadius'] = + this.contentContainer_.style['MozBorderRadius'] = + this.contentContainer_.style['webkitBorderRadius'] = + this.bubbleShadow_.style['borderRadius'] = + this.bubbleShadow_.style['MozBorderRadius'] = + this.bubbleShadow_.style['webkitBorderRadius'] = this.px(borderRadius); + + this.tabsContainer_.style['paddingLeft'] = + this.tabsContainer_.style['paddingRight'] = + this.px(borderRadius + borderWidth); + + this.redraw_(); +}; +InfoBubble.prototype['borderRadius_changed'] = + InfoBubble.prototype.borderRadius_changed; + + +/** + * Get the width of the border + * + * @private + * @return {number} width The width of the border. + */ +InfoBubble.prototype.getBorderWidth_ = function() { + return parseInt(this.get('borderWidth'), 10) || 0; +}; + + +/** + * Set the width of the border + * + * @param {number} width The width of the border. + */ +InfoBubble.prototype.setBorderWidth = function(width) { + this.set('borderWidth', width); +}; +InfoBubble.prototype['setBorderWidth'] = InfoBubble.prototype.setBorderWidth; + + +/** + * borderWidth change MVC callback + */ +InfoBubble.prototype.borderWidth_changed = function() { + var borderWidth = this.getBorderWidth_(); + + this.contentContainer_.style['borderWidth'] = this.px(borderWidth); + this.tabsContainer_.style['top'] = this.px(borderWidth); + + this.updateArrowStyle_(); + this.updateTabStyles_(); + this.borderRadius_changed(); + this.redraw_(); +}; +InfoBubble.prototype['borderWidth_changed'] = + InfoBubble.prototype.borderWidth_changed; + + +/** + * Update the arrow style + * @private + */ +InfoBubble.prototype.updateArrowStyle_ = function() { + var borderWidth = this.getBorderWidth_(); + var arrowSize = this.getArrowSize_(); + var arrowStyle = this.getArrowStyle_(); + var arrowOuterSizePx = this.px(arrowSize); + var arrowInnerSizePx = this.px(Math.max(0, arrowSize - borderWidth)); + + var outer = this.arrowOuter_; + var inner = this.arrowInner_; + + this.arrow_.style['marginTop'] = this.px(-borderWidth); + outer.style['borderTopWidth'] = arrowOuterSizePx; + inner.style['borderTopWidth'] = arrowInnerSizePx; + + // Full arrow or arrow pointing to the left + if (arrowStyle == 0 || arrowStyle == 1) { + outer.style['borderLeftWidth'] = arrowOuterSizePx; + inner.style['borderLeftWidth'] = arrowInnerSizePx; + } else { + outer.style['borderLeftWidth'] = inner.style['borderLeftWidth'] = 0; + } + + // Full arrow or arrow pointing to the right + if (arrowStyle == 0 || arrowStyle == 2) { + outer.style['borderRightWidth'] = arrowOuterSizePx; + inner.style['borderRightWidth'] = arrowInnerSizePx; + } else { + outer.style['borderRightWidth'] = inner.style['borderRightWidth'] = 0; + } + + if (arrowStyle < 2) { + outer.style['marginLeft'] = this.px(-(arrowSize)); + inner.style['marginLeft'] = this.px(-(arrowSize - borderWidth)); + } else { + outer.style['marginLeft'] = inner.style['marginLeft'] = 0; + } + + // If there is no border then don't show thw outer arrow + if (borderWidth == 0) { + outer.style['display'] = 'none'; + } else { + outer.style['display'] = ''; + } +}; + + +/** + * Set the padding of the InfoBubble + * + * @param {number} padding The padding to apply. + */ +InfoBubble.prototype.setPadding = function(padding) { + this.set('padding', padding); +}; +InfoBubble.prototype['setPadding'] = InfoBubble.prototype.setPadding; + + +/** + * Set the padding of the InfoBubble + * + * @private + * @return {number} padding The padding to apply. + */ +InfoBubble.prototype.getPadding_ = function() { + return parseInt(this.get('padding'), 10) || 0; +}; + + +/** + * padding changed MVC callback + */ +InfoBubble.prototype.padding_changed = function() { + var padding = this.getPadding_(); + this.contentContainer_.style['padding'] = this.px(padding); + this.updateTabStyles_(); + + this.redraw_(); +}; +InfoBubble.prototype['padding_changed'] = InfoBubble.prototype.padding_changed; + + +/** + * Add px extention to the number + * + * @param {number} num The number to wrap. + * @return {string|number} A wrapped number. + */ +InfoBubble.prototype.px = function(num) { + if (num) { + // 0 doesn't need to be wrapped + return num + 'px'; + } + return num; +}; + + +/** + * Add events to stop propagation + * @private + */ +InfoBubble.prototype.addEvents_ = function() { + // We want to cancel all the events so they do not go to the map + var events = ['mousedown', 'mousemove', 'mouseover', 'mouseout', 'mouseup', + 'mousewheel', 'DOMMouseScroll', 'touchstart', 'touchend', 'touchmove', + 'dblclick', 'contextmenu', 'click']; + + var bubble = this.bubble_; + this.listeners_ = []; + for (var i = 0, event; event = events[i]; i++) { + this.listeners_.push( + google.maps.event.addDomListener(bubble, event, function(e) { + e.cancelBubble = true; + if (e.stopPropagation) { + e.stopPropagation(); + } + }) + ); + } +}; + + +/** + * On Adding the InfoBubble to a map + * Implementing the OverlayView interface + */ +InfoBubble.prototype.onAdd = function() { + if (!this.bubble_) { + this.buildDom_(); + } + + this.addEvents_(); + + var panes = this.getPanes(); + if (panes) { + panes.floatPane.appendChild(this.bubble_); + panes.floatShadow.appendChild(this.bubbleShadow_); + } +}; +InfoBubble.prototype['onAdd'] = InfoBubble.prototype.onAdd; + + +/** + * Draw the InfoBubble + * Implementing the OverlayView interface + */ +InfoBubble.prototype.draw = function() { + var projection = this.getProjection(); + + if (!projection) { + // The map projection is not ready yet so do nothing + return; + } + + var latLng = /** @type {google.maps.LatLng} */ (this.get('position')); + + if (!latLng) { + this.close(); + return; + } + + var tabHeight = 0; + + if (this.activeTab_) { + tabHeight = this.activeTab_.offsetHeight; + } + + var anchorHeight = this.getAnchorHeight_(); + var arrowSize = this.getArrowSize_(); + var arrowPosition = this.getArrowPosition_(); + + arrowPosition = arrowPosition / 100; + + var pos = projection.fromLatLngToDivPixel(latLng); + var width = this.contentContainer_.offsetWidth; + var height = this.bubble_.offsetHeight; + + if (!width) { + return; + } + + // Adjust for the height of the info bubble + var top = pos.y - (height + arrowSize); + + if (anchorHeight) { + // If there is an anchor then include the height + top -= anchorHeight; + } + + var left = pos.x - (width * arrowPosition); + + this.bubble_.style['top'] = this.px(top); + this.bubble_.style['left'] = this.px(left); + + var shadowStyle = parseInt(this.get('shadowStyle'), 10); + + switch (shadowStyle) { + case 1: + // Shadow is behind + this.bubbleShadow_.style['top'] = this.px(top + tabHeight - 1); + this.bubbleShadow_.style['left'] = this.px(left); + this.bubbleShadow_.style['width'] = this.px(width); + this.bubbleShadow_.style['height'] = + this.px(this.contentContainer_.offsetHeight - arrowSize); + break; + case 2: + // Shadow is below + width = width * 0.8; + if (anchorHeight) { + this.bubbleShadow_.style['top'] = this.px(pos.y); + } else { + this.bubbleShadow_.style['top'] = this.px(pos.y + arrowSize); + } + this.bubbleShadow_.style['left'] = this.px(pos.x - width * arrowPosition); + + this.bubbleShadow_.style['width'] = this.px(width); + this.bubbleShadow_.style['height'] = this.px(2); + break; + } +}; +InfoBubble.prototype['draw'] = InfoBubble.prototype.draw; + + +/** + * Removing the InfoBubble from a map + */ +InfoBubble.prototype.onRemove = function() { + if (this.bubble_ && this.bubble_.parentNode) { + this.bubble_.parentNode.removeChild(this.bubble_); + } + if (this.bubbleShadow_ && this.bubbleShadow_.parentNode) { + this.bubbleShadow_.parentNode.removeChild(this.bubbleShadow_); + } + + for (var i = 0, listener; listener = this.listeners_[i]; i++) { + google.maps.event.removeListener(listener); + } +}; +InfoBubble.prototype['onRemove'] = InfoBubble.prototype.onRemove; + + +/** + * Is the InfoBubble open + * + * @return {boolean} If the InfoBubble is open. + */ +InfoBubble.prototype.isOpen = function() { + return this.isOpen_; +}; +InfoBubble.prototype['isOpen'] = InfoBubble.prototype.isOpen; + + +/** + * Close the InfoBubble + */ +InfoBubble.prototype.close = function() { + if (this.bubble_) { + this.bubble_.style['display'] = 'none'; + // Remove the animation so we next time it opens it will animate again + this.bubble_.className = + this.bubble_.className.replace(this.animationName_, ''); + } + + if (this.bubbleShadow_) { + this.bubbleShadow_.style['display'] = 'none'; + this.bubbleShadow_.className = + this.bubbleShadow_.className.replace(this.animationName_, ''); + } + this.isOpen_ = false; +}; +InfoBubble.prototype['close'] = InfoBubble.prototype.close; + + +/** + * Open the InfoBubble (asynchronous). + * + * @param {google.maps.Map=} opt_map Optional map to open on. + * @param {google.maps.MVCObject=} opt_anchor Optional anchor to position at. + */ +InfoBubble.prototype.open = function(opt_map, opt_anchor) { + var that = this; + window.setTimeout(function() { + that.open_(opt_map, opt_anchor); + }, 0); +}; + +/** + * Open the InfoBubble + * @private + * @param {google.maps.Map=} opt_map Optional map to open on. + * @param {google.maps.MVCObject=} opt_anchor Optional anchor to position at. + */ +InfoBubble.prototype.open_ = function(opt_map, opt_anchor) { + this.updateContent_(); + + if (opt_map) { + this.setMap(opt_map); + } + + if (opt_anchor) { + this.set('anchor', opt_anchor); + this.bindTo('anchorPoint', opt_anchor); + this.bindTo('position', opt_anchor); + } + + // Show the bubble and the show + this.bubble_.style['display'] = this.bubbleShadow_.style['display'] = ''; + var animation = !this.get('disableAnimation'); + + if (animation) { + // Add the animation + this.bubble_.className += ' ' + this.animationName_; + this.bubbleShadow_.className += ' ' + this.animationName_; + } + + this.redraw_(); + this.isOpen_ = true; + + var pan = !this.get('disableAutoPan'); + if (pan) { + var that = this; + window.setTimeout(function() { + // Pan into view, done in a time out to make it feel nicer :) + that.panToView(); + }, 200); + } +}; +InfoBubble.prototype['open'] = InfoBubble.prototype.open; + + +/** + * Set the position of the InfoBubble + * + * @param {google.maps.LatLng} position The position to set. + */ +InfoBubble.prototype.setPosition = function(position) { + if (position) { + this.set('position', position); + } +}; +InfoBubble.prototype['setPosition'] = InfoBubble.prototype.setPosition; + + +/** + * Returns the position of the InfoBubble + * + * @return {google.maps.LatLng} the position. + */ +InfoBubble.prototype.getPosition = function() { + return /** @type {google.maps.LatLng} */ (this.get('position')); +}; +InfoBubble.prototype['getPosition'] = InfoBubble.prototype.getPosition; + + +/** + * position changed MVC callback + */ +InfoBubble.prototype.position_changed = function() { + this.draw(); +}; +InfoBubble.prototype['position_changed'] = + InfoBubble.prototype.position_changed; + + +/** + * Pan the InfoBubble into view + */ +InfoBubble.prototype.panToView = function() { + var projection = this.getProjection(); + + if (!projection) { + // The map projection is not ready yet so do nothing + return; + } + + if (!this.bubble_) { + // No Bubble yet so do nothing + return; + } + + var anchorHeight = this.getAnchorHeight_(); + var height = this.bubble_.offsetHeight + anchorHeight; + var map = this.get('map'); + var mapDiv = map.getDiv(); + var mapHeight = mapDiv.offsetHeight; + + var latLng = this.getPosition(); + var centerPos = projection.fromLatLngToContainerPixel(map.getCenter()); + var pos = projection.fromLatLngToContainerPixel(latLng); + + // Find out how much space at the top is free + var spaceTop = centerPos.y - height; + + // Fine out how much space at the bottom is free + var spaceBottom = mapHeight - centerPos.y; + + var needsTop = spaceTop < 0; + var deltaY = 0; + + if (needsTop) { + spaceTop *= -1; + deltaY = (spaceTop + spaceBottom) / 2; + } + + pos.y -= deltaY; + latLng = projection.fromContainerPixelToLatLng(pos); + + if (map.getCenter() != latLng) { + map.panTo(latLng); + } +}; +InfoBubble.prototype['panToView'] = InfoBubble.prototype.panToView; + + +/** + * Converts a HTML string to a document fragment. + * + * @param {string} htmlString The HTML string to convert. + * @return {Node} A HTML document fragment. + * @private + */ +InfoBubble.prototype.htmlToDocumentFragment_ = function(htmlString) { + htmlString = htmlString.replace(/^\s*([\S\s]*)\b\s*$/, '$1'); + var tempDiv = document.createElement('DIV'); + tempDiv.innerHTML = htmlString; + if (tempDiv.childNodes.length == 1) { + return /** @type {!Node} */ (tempDiv.removeChild(tempDiv.firstChild)); + } else { + var fragment = document.createDocumentFragment(); + while (tempDiv.firstChild) { + fragment.appendChild(tempDiv.firstChild); + } + return fragment; + } +}; + + +/** + * Removes all children from the node. + * + * @param {Node} node The node to remove all children from. + * @private + */ +InfoBubble.prototype.removeChildren_ = function(node) { + if (!node) { + return; + } + + var child; + while (child = node.firstChild) { + node.removeChild(child); + } +}; + + +/** + * Sets the content of the infobubble. + * + * @param {string|Node} content The content to set. + */ +InfoBubble.prototype.setContent = function(content) { + this.set('content', content); +}; +InfoBubble.prototype['setContent'] = InfoBubble.prototype.setContent; + + +/** + * Get the content of the infobubble. + * + * @return {string|Node} The marker content. + */ +InfoBubble.prototype.getContent = function() { + return /** @type {Node|string} */ (this.get('content')); +}; +InfoBubble.prototype['getContent'] = InfoBubble.prototype.getContent; + + +/** + * Sets the marker content and adds loading events to images + */ +InfoBubble.prototype.updateContent_ = function() { + if (!this.content_) { + // The Content area doesnt exist. + return; + } + + this.removeChildren_(this.content_); + var content = this.getContent(); + if (content) { + if (typeof content == 'string') { + content = this.htmlToDocumentFragment_(content); + } + this.content_.appendChild(content); + + var that = this; + var images = this.content_.getElementsByTagName('IMG'); + for (var i = 0, image; image = images[i]; i++) { + // Because we don't know the size of an image till it loads, add a + // listener to the image load so the marker can resize and reposition + // itself to be the correct height. + google.maps.event.addDomListener(image, 'load', function() { + that.imageLoaded_(); + }); + } + google.maps.event.trigger(this, 'domready'); + } + this.redraw_(); +}; + +/** + * Image loaded + * @private + */ +InfoBubble.prototype.imageLoaded_ = function() { + var pan = !this.get('disableAutoPan'); + this.redraw_(); + if (pan && (this.tabs_.length == 0 || this.activeTab_.index == 0)) { + this.panToView(); + } +}; + +/** + * Updates the styles of the tabs + * @private + */ +InfoBubble.prototype.updateTabStyles_ = function() { + if (this.tabs_ && this.tabs_.length) { + for (var i = 0, tab; tab = this.tabs_[i]; i++) { + this.setTabStyle_(tab.tab); + } + this.activeTab_.style['zIndex'] = this.baseZIndex_; + var borderWidth = this.getBorderWidth_(); + var padding = this.getPadding_() / 2; + this.activeTab_.style['borderBottomWidth'] = 0; + this.activeTab_.style['paddingBottom'] = this.px(padding + borderWidth); + } +}; + + +/** + * Sets the style of a tab + * @private + * @param {Element} tab The tab to style. + */ +InfoBubble.prototype.setTabStyle_ = function(tab) { + var backgroundColor = this.get('backgroundColor'); + var borderColor = this.get('borderColor'); + var borderRadius = this.getBorderRadius_(); + var borderWidth = this.getBorderWidth_(); + var padding = this.getPadding_(); + + var marginRight = this.px(-(Math.max(padding, borderRadius))); + var borderRadiusPx = this.px(borderRadius); + + var index = this.baseZIndex_; + if (tab.index) { + index -= tab.index; + } + + // The styles for the tab + var styles = { + 'cssFloat': 'left', + 'position': 'relative', + 'cursor': 'pointer', + 'backgroundColor': backgroundColor, + 'border': this.px(borderWidth) + ' solid ' + borderColor, + 'padding': this.px(padding / 2) + ' ' + this.px(padding), + 'marginRight': marginRight, + 'whiteSpace': 'nowrap', + 'borderRadiusTopLeft': borderRadiusPx, + 'MozBorderRadiusTopleft': borderRadiusPx, + 'webkitBorderTopLeftRadius': borderRadiusPx, + 'borderRadiusTopRight': borderRadiusPx, + 'MozBorderRadiusTopright': borderRadiusPx, + 'webkitBorderTopRightRadius': borderRadiusPx, + 'zIndex': index, + 'display': 'inline' + }; + + for (var style in styles) { + tab.style[style] = styles[style]; + } + + var className = this.get('tabClassName'); + if (className != undefined) { + tab.className += ' ' + className; + } +}; + + +/** + * Add user actions to a tab + * @private + * @param {Object} tab The tab to add the actions to. + */ +InfoBubble.prototype.addTabActions_ = function(tab) { + var that = this; + tab.listener_ = google.maps.event.addDomListener(tab, 'click', function() { + that.setTabActive_(this); + }); +}; + + +/** + * Set a tab at a index to be active + * + * @param {number} index The index of the tab. + */ +InfoBubble.prototype.setTabActive = function(index) { + var tab = this.tabs_[index - 1]; + + if (tab) { + this.setTabActive_(tab.tab); + } +}; +InfoBubble.prototype['setTabActive'] = InfoBubble.prototype.setTabActive; + + +/** + * Set a tab to be active + * @private + * @param {Object} tab The tab to set active. + */ +InfoBubble.prototype.setTabActive_ = function(tab) { + if (!tab) { + this.setContent(''); + this.updateContent_(); + return; + } + + var padding = this.getPadding_() / 2; + var borderWidth = this.getBorderWidth_(); + + if (this.activeTab_) { + var activeTab = this.activeTab_; + activeTab.style['zIndex'] = this.baseZIndex_ - activeTab.index; + activeTab.style['paddingBottom'] = this.px(padding); + activeTab.style['borderBottomWidth'] = this.px(borderWidth); + } + + tab.style['zIndex'] = this.baseZIndex_; + tab.style['borderBottomWidth'] = 0; + tab.style['marginBottomWidth'] = '-10px'; + tab.style['paddingBottom'] = this.px(padding + borderWidth); + + this.setContent(this.tabs_[tab.index].content); + this.updateContent_(); + + this.activeTab_ = tab; + + this.redraw_(); +}; + + +/** + * Set the max width of the InfoBubble + * + * @param {number} width The max width. + */ +InfoBubble.prototype.setMaxWidth = function(width) { + this.set('maxWidth', width); +}; +InfoBubble.prototype['setMaxWidth'] = InfoBubble.prototype.setMaxWidth; + + +/** + * maxWidth changed MVC callback + */ +InfoBubble.prototype.maxWidth_changed = function() { + this.redraw_(); +}; +InfoBubble.prototype['maxWidth_changed'] = + InfoBubble.prototype.maxWidth_changed; + + +/** + * Set the max height of the InfoBubble + * + * @param {number} height The max height. + */ +InfoBubble.prototype.setMaxHeight = function(height) { + this.set('maxHeight', height); +}; +InfoBubble.prototype['setMaxHeight'] = InfoBubble.prototype.setMaxHeight; + + +/** + * maxHeight changed MVC callback + */ +InfoBubble.prototype.maxHeight_changed = function() { + this.redraw_(); +}; +InfoBubble.prototype['maxHeight_changed'] = + InfoBubble.prototype.maxHeight_changed; + + +/** + * Set the min width of the InfoBubble + * + * @param {number} width The min width. + */ +InfoBubble.prototype.setMinWidth = function(width) { + this.set('minWidth', width); +}; +InfoBubble.prototype['setMinWidth'] = InfoBubble.prototype.setMinWidth; + + +/** + * minWidth changed MVC callback + */ +InfoBubble.prototype.minWidth_changed = function() { + this.redraw_(); +}; +InfoBubble.prototype['minWidth_changed'] = + InfoBubble.prototype.minWidth_changed; + + +/** + * Set the min height of the InfoBubble + * + * @param {number} height The min height. + */ +InfoBubble.prototype.setMinHeight = function(height) { + this.set('minHeight', height); +}; +InfoBubble.prototype['setMinHeight'] = InfoBubble.prototype.setMinHeight; + + +/** + * minHeight changed MVC callback + */ +InfoBubble.prototype.minHeight_changed = function() { + this.redraw_(); +}; +InfoBubble.prototype['minHeight_changed'] = + InfoBubble.prototype.minHeight_changed; + + +/** + * Add a tab + * + * @param {string} label The label of the tab. + * @param {string|Element} content The content of the tab. + */ +InfoBubble.prototype.addTab = function(label, content) { + var tab = document.createElement('DIV'); + tab.innerHTML = label; + + this.setTabStyle_(tab); + this.addTabActions_(tab); + + this.tabsContainer_.appendChild(tab); + + this.tabs_.push({ + label: label, + content: content, + tab: tab + }); + + tab.index = this.tabs_.length - 1; + tab.style['zIndex'] = this.baseZIndex_ - tab.index; + + if (!this.activeTab_) { + this.setTabActive_(tab); + } + + tab.className = tab.className; // + ' ' + this.animationName_; get rid of annoying animation on tabs + + this.redraw_(); +}; +InfoBubble.prototype['addTab'] = InfoBubble.prototype.addTab; + +/** + * Update a tab at a speicifc index + * + * @param {number} index The index of the tab. + * @param {?string} opt_label The label to change to. + * @param {?string} opt_content The content to update to. + */ +InfoBubble.prototype.updateTab = function(index, opt_label, opt_content) { + if (!this.tabs_.length || index < 0 || index >= this.tabs_.length) { + return; + } + + var tab = this.tabs_[index]; + if (opt_label != undefined) { + tab.tab.innerHTML = tab.label = opt_label; + } + + if (opt_content != undefined) { + tab.content = opt_content; + } + + if (this.activeTab_ == tab.tab) { + this.setContent(tab.content); + this.updateContent_(); + } + this.redraw_(); +}; +InfoBubble.prototype['updateTab'] = InfoBubble.prototype.updateTab; + + +/** + * Remove a tab at a specific index + * + * @param {number} index The index of the tab to remove. + */ +InfoBubble.prototype.removeTab = function(index) { + if (!this.tabs_.length || index < 0 || index >= this.tabs_.length) { + return; + } + + var tab = this.tabs_[index]; + tab.tab.parentNode.removeChild(tab.tab); + + google.maps.event.removeListener(tab.tab.listener_); + + this.tabs_.splice(index, 1); + + delete tab; + + for (var i = 0, t; t = this.tabs_[i]; i++) { + t.tab.index = i; + } + + if (tab.tab == this.activeTab_) { + // Removing the current active tab + if (this.tabs_[index]) { + // Show the tab to the right + this.activeTab_ = this.tabs_[index].tab; + } else if (this.tabs_[index - 1]) { + // Show a tab to the left + this.activeTab_ = this.tabs_[index - 1].tab; + } else { + // No tabs left to sho + this.activeTab_ = undefined; + } + + this.setTabActive_(this.activeTab_); + } + + this.redraw_(); +}; +InfoBubble.prototype['removeTab'] = InfoBubble.prototype.removeTab; + + +/** + * Get the size of an element + * @private + * @param {Node|string} element The element to size. + * @param {number=} opt_maxWidth Optional max width of the element. + * @param {number=} opt_maxHeight Optional max height of the element. + * @return {google.maps.Size} The size of the element. + */ +InfoBubble.prototype.getElementSize_ = function(element, opt_maxWidth, + opt_maxHeight) { + var sizer = document.createElement('DIV'); + sizer.style['display'] = 'inline'; + sizer.style['position'] = 'absolute'; + sizer.style['visibility'] = 'hidden'; + + if (typeof element == 'string') { + sizer.innerHTML = element; + } else { + sizer.appendChild(element.cloneNode(true)); + } + + document.body.appendChild(sizer); + var size = new google.maps.Size(sizer.offsetWidth, sizer.offsetHeight); + + // If the width is bigger than the max width then set the width and size again + if (opt_maxWidth && size.width > opt_maxWidth) { + sizer.style['width'] = this.px(opt_maxWidth); + size = new google.maps.Size(sizer.offsetWidth, sizer.offsetHeight); + } + + // If the height is bigger than the max height then set the height and size + // again + if (opt_maxHeight && size.height > opt_maxHeight) { + sizer.style['height'] = this.px(opt_maxHeight); + size = new google.maps.Size(sizer.offsetWidth, sizer.offsetHeight); + } + + document.body.removeChild(sizer); + delete sizer; + return size; +}; + + +/** + * Redraw the InfoBubble + * @private + */ +InfoBubble.prototype.redraw_ = function() { + this.figureOutSize_(); + this.positionCloseButton_(); + this.draw(); +}; + + +/** + * Figure out the optimum size of the InfoBubble + * @private + */ +InfoBubble.prototype.figureOutSize_ = function() { + var map = this.get('map'); + + if (!map) { + return; + } + + var padding = this.getPadding_(); + var borderWidth = this.getBorderWidth_(); + var borderRadius = this.getBorderRadius_(); + var arrowSize = this.getArrowSize_(); + + var mapDiv = map.getDiv(); + var gutter = arrowSize * 2; + var mapWidth = mapDiv.offsetWidth - gutter; + var mapHeight = mapDiv.offsetHeight - gutter - this.getAnchorHeight_(); + var tabHeight = 0; + var width = /** @type {number} */ (this.get('minWidth') || 0); + var height = /** @type {number} */ (this.get('minHeight') || 0); + var maxWidth = /** @type {number} */ (this.get('maxWidth') || 0); + var maxHeight = /** @type {number} */ (this.get('maxHeight') || 0); + + maxWidth = Math.min(mapWidth, maxWidth); + maxHeight = Math.min(mapHeight, maxHeight); + + var tabWidth = 0; + if (this.tabs_.length) { + // If there are tabs then you need to check the size of each tab's content + for (var i = 0, tab; tab = this.tabs_[i]; i++) { + var tabSize = this.getElementSize_(tab.tab, maxWidth, maxHeight); + var contentSize = this.getElementSize_(tab.content, maxWidth, maxHeight); + + if (width < tabSize.width) { + width = tabSize.width; + } + + // Add up all the tab widths because they might end up being wider than + // the content + tabWidth += tabSize.width; + + if (height < tabSize.height) { + height = tabSize.height; + } + + if (tabSize.height > tabHeight) { + tabHeight = tabSize.height; + } + + if (width < contentSize.width) { + width = contentSize.width; + } + + if (height < contentSize.height) { + height = contentSize.height; + } + } + } else { + var content = /** @type {string|Node} */ (this.get('content')); + if (typeof content == 'string') { + content = this.htmlToDocumentFragment_(content); + } + if (content) { + var contentSize = this.getElementSize_(content, maxWidth, maxHeight); + + if (width < contentSize.width) { + width = contentSize.width; + } + + if (height < contentSize.height) { + height = contentSize.height; + } + } + } + + if (maxWidth) { + width = Math.min(width, maxWidth); + } + + if (maxHeight) { + height = Math.min(height, maxHeight); + } + + width = Math.max(width, tabWidth); + + if (width == tabWidth) { + width = width + 2 * padding; + } + + arrowSize = arrowSize * 2; + width = Math.max(width, arrowSize); + + // Maybe add this as a option so they can go bigger than the map if the user + // wants + if (width > mapWidth) { + width = mapWidth; + } + + if (height > mapHeight) { + height = mapHeight - tabHeight; + } + + if (this.tabsContainer_) { + this.tabHeight_ = tabHeight; + this.tabsContainer_.style['width'] = this.px(tabWidth); + } + + this.contentContainer_.style['width'] = this.px(width); + this.contentContainer_.style['height'] = this.px(height); +}; + + +/** + * Get the height of the anchor + * + * This function is a hack for now and doesn't really work that good, need to + * wait for pixelBounds to be correctly exposed. + * @private + * @return {number} The height of the anchor. + */ +InfoBubble.prototype.getAnchorHeight_ = function() { + var anchor = this.get('anchor'); + if (anchor) { + var anchorPoint = /** @type google.maps.Point */(this.get('anchorPoint')); + + if (anchorPoint) { + return -1 * anchorPoint.y; + } + } + return 0; +}; + +InfoBubble.prototype.anchorPoint_changed = function() { + this.draw(); +}; +InfoBubble.prototype['anchorPoint_changed'] = InfoBubble.prototype.anchorPoint_changed; + + +/** + * Position the close button in the right spot. + * @private + */ +InfoBubble.prototype.positionCloseButton_ = function() { + var br = this.getBorderRadius_(); + var bw = this.getBorderWidth_(); + + var right = 2; + var top = 2; + + if (this.tabs_.length && this.tabHeight_) { + top += this.tabHeight_; + } + + top += bw; + right += bw; + + var c = this.contentContainer_; + if (c && c.clientHeight < c.scrollHeight) { + // If there are scrollbars then move the cross in so it is not over + // scrollbar + right += 15; + } + + this.close_.style['right'] = this.px(right); + this.close_.style['top'] = this.px(top); +}; diff --git a/loadTable.php b/loadTable.php new file mode 100755 index 0000000..5497522 --- /dev/null +++ b/loadTable.php @@ -0,0 +1,30 @@ + diff --git a/map.js b/map.js new file mode 100755 index 0000000..748e9ae --- /dev/null +++ b/map.js @@ -0,0 +1,682 @@ +//tool to update dataase: display markers and edit positions +//http://docs.jquery.com/Ajax/jQuery.getJSON#urldatacallback +//nb in google maps it says "DIT" in the middle of the provost's stables +/* +showPlaces(type) +showPlace(index) + + + +*/ +//------------------------------------------------------------------------globals +var http = getHTTPObject(); //old ajax method +var markers=[]; +var markertypes=['Building','Parking','Entrances']; //--lat/lng based tables to create markers +var tables=[]; +var tablenames=['AZ','Lecture_theatres','Pacr','Libraries','Loops','Enabled_toilets']; //--tables reference building table +var tablescreennames={'Lecture_theatres':"Lecture theatres",'Pacr':"Public access computer rooms",'Libraries':"Libraries",'Loops':"Hearing aid looops",'Enabled_toilets':"Enabled toilets"}; +var icontypes=['Loops','Enabled_toilets']; +var places=[]; +var placetypes=new Array('Lecture_theatres','Libraries','Pacr'); +var screenplacetypes=new Array('Lecture theatres','Libraries','Public access computer rooms'); +for (i=0;i1||this.description) { //multi-tab + this.showtab = function() { + purgeInfoWindow(); + InfoWindow=new InfoBubble({disableAnimation:true}); + InfoWindow.addTab('Building',this.getPlacesTab()); + InfoWindow.addTab('More',this.getInfoTab()); + InfoWindow.open(map,this); + this.tabVisible=true; + } + } //single tab + else { + this.showtab = function() { + purgeInfoWindow(); + InfoWindow=new InfoBubble({content:this.getPlacesTab(),disableAnimation:true});; + InfoWindow.open(map,this); + this.tabVisible=true; + } + } + G.event.addListener(this,"click",this.showtab); + this.setMap(map); + var boundscheck=map.getBounds(); + if ((!boundscheck.contains(this.getPosition()))&&this.type=="Building") //only zoom to accomodate buildings + { + boundscheck.extend(this.getPosition()); + var newzoom = getZoomByBounds( map, boundscheck ); + map.setZoom(newzoom); + map.setCenter(boundscheck.getCenter()); + + } + this.visible=true; + } + if (tab) this.showtab(); + } + } + if (type=="Entrances") { //construct tabs + m.show = function (tab){ + this.showtab = function() { + purgeInfoWindow(); + InfoWindow=new InfoBubble({content:this.getEntranceTab(),disableAnimation:true}); + InfoWindow.open(map,this); + this.tabVisible=true; + } + G.event.addListener(this,"click",this.showtab); + this.setMap(map); + var boundscheck=map.getBounds(); + if ((!boundscheck.contains(this.getPosition()))&&this.type=="Building") //only zoom to accomodate buildings + { + boundscheck.extend(this.getPosition()); + var newzoom = getZoomByBounds( map, boundscheck ); + if (newzoom<15) map.setMapType(G_NORMAL_MAP); + map.setZoom(newzoom); + map.setCenter(boundscheck.getCenter()); + } + this.visible=true; + if (tab) this.showtab(); + } + } + if (type=="Enabled_toilets") { //construct tabs + m.show = function (tab){ + if (this.data !="") { + this.showtab = function() { + purgeInfoWindow(); + InfoWindow=new InfoBubble({content:this.getToiletTab(),disableAnimation:true}); + InfoWindow.open(map,this); + this.tabVisible=true; + } + } + G.event.addListener(this,"click",this.showtab); + this.setMap(map); + var boundscheck=map.getBounds(); + if ((!boundscheck.contains(this.getPosition()))&&this.type=="Building") //only zoom to accomodate buildings + { + boundscheck.extend(this.getPosition()); + var newzoom = getZoomByBounds( map, boundscheck ); + if (newzoom<15) map.setMapType(G_NORMAL_MAP); + map.setZoom(newzoom); + map.setCenter(boundscheck.getCenter()); + } + this.visible=true; + if (tab) this.showtab(); + } + } + if (type=="Loops"||type=="Parking") { + m.show = function (tab){ + this.setMap(map); + var boundscheck=map.getBounds(); + if ((!boundscheck.contains(this.getPosition()))&&this.type=="Building") //only zoom to accomodate buildings + { + boundscheck.extend(this.getPosition()); + var newzoom = getZoomByBounds( map, boundscheck ); + if (newzoom<15) map.setMapType(G_NORMAL_MAP); + map.setZoom(newzoom); + map.setCenter(boundscheck.getCenter()); + } + this.visible=true; + } + } + m.hide = function() { + if (!(this.type=="Loops"||this.type=="Parking")) { + G.event.clearListeners(this,"click"); + } + if (this.tabVisible) { + purgeInfoWindow(); + this.tabVisible=false; + } + this.visible=false; + this.setMap(null); + } + m.getPlacesTab=getPlacesTab; + m.getInfoTab=getInfoTab; + m.getEntranceTab=getEntranceTab; + m.getToiletTab=getToiletTab; + return m; +} +//----------------------------------------------------------------------------------functions to populate tabs called from marker +function getPlacesTab() { + var popup="

"+this.name+"

"; + popup+="
"; + if (this.dispphoto) { + popup+="
"; + popup+=""; + popup+="
"; + } + if (this.opening_hours) { + popup+="
"; + popup +='
Building Opening Hours:
'; + popup +='
'+this.opening_hours+"
"; + popup+="
"; + } + if ((this.accessibility)||(this.accessibility_url)) { + popup+="
"; + if (this.accessibility) { + popup+="
Accessibility:
"+this.accessibility+" "; + if (this.accessibility_url) popup+="(more info)
"; + + } + else if (this.accessibility_url) popup+=""; + popup+="
"; + } + popup+="
"; + + popup+=""; + + return popup; +} +function getInfoTab() { + popup=""; + popup+="
"; + popup+="
"; //
"; + var placeoffset=0; + if (this.places.length-placeoffset) { + popup+="

Also in this building

    "; + for (i=0;i"+this.places[i].name+""; + } + else { + popup +="
  • "+this.places[i].name+"
  • "; + } + } + } + popup+="
"; + } + if (this.description) popup+="

Info

"+this.description; + popup+="
"; + return popup; +} +function getToiletTab() { + popup=""; + popup+="
"; + popup+="
"; + popup+="

Enabled toilet

" + popup+="
"+this.data; + popup+="
"; + return popup; +} +function getEntranceTab() { + popup=""; + popup+="
"; + popup+="
"; + popup+="

Entrance

" + popup+="
"+this.data; + popup+="
"; + return popup; +} +//----------------------------------------------------------------------------------Setting up data structures while loading +function prepareData() { + //create markers for ref tables + for (i in icontypes) { + markers[icontypes[i]]=[]; + for (t in tables[icontypes[i]]) { + //console.log("building "+tables[icontypes[i]][t].building+":"+markers["Building"][tables[icontypes[i]][t].building].name); + tables[icontypes[i]][t].lat=markers["Building"][tables[icontypes[i]][t].building].lat; + tables[icontypes[i]][t].lng=markers["Building"][tables[icontypes[i]][t].building].lng; + tables[icontypes[i]][t].id=tables[icontypes[i]][t].building; + markers[icontypes[i]].push(makeMarker(tables[icontypes[i]][t],icontypes[i])); + } + + markers[icontypes[i]].visible=false; + } + //process Building and AZ tables + //create AZ -- is causing problems now for some reason WHERE THERE ARE NO ITEMS + for (var i=0;i<26;i++) { + tables[String.fromCharCode(i+65)]=[]; + tables[String.fromCharCode(i+65)].screenname=String.fromCharCode(i+65); + } + //Create alphabetical lists of places including exceptions + for (var i=0;i25) startlet-=32; //select small letters (which shouldn't even be there) + + if ((startlet==96)||(startlet==128)) startlet=0; //catch Á + if (startlet==104) startlet=4; //catch É + if (startlet==108) startlet=8; //catch Í + + //find array number of building index as buildingindex number can be non-consecutive + var bb=tables["AZ"][i].building; + for (j in markers['Building']) + { + if (markers['Building'][j].id==bb) { + numplaces=tables[String.fromCharCode(startlet+65)].length; + tables[String.fromCharCode(startlet+65)].push(tables["AZ"][i]); //add reference to place + tables[String.fromCharCode(startlet+65)][numplaces].building=j; //resolve reference to building array + tables[String.fromCharCode(startlet+65)][numplaces].index=i; //resolve reference to AZ array + markers['Building'][j].places.push(tables["AZ"][i]); + } + } + + if (tables["AZ"][i].name.slice(0,3)=="St.") + { + startlet=tables["AZ"][i].name.charCodeAt(4) -65; + if (startlet>25) startlet-=32; //select small letters + //we know its doesn't start with ÁÉÍ + for (j in markers['Building']) + { + if (markers['Building'][j].id==bb) { + numplaces=tables[String.fromCharCode(startlet+65)].length; + tables[String.fromCharCode(startlet+65)].push(tables["AZ"][i]); //add reference to place + tables[String.fromCharCode(startlet+65)][numplaces].building=j; //resolve reference to building array + markers['Building'][j].places.push(tables["AZ"][i]); + } + } + } + } + //add buildings + for (i in markers['Building']) + { + if (markers['Building'][i].name) { //trap added 'visible' property + var j=0; + var startlet=0; + + while (markers['Building'][i].name.charCodeAt(j) <64) j++; //find 1st non-number + + startlet=markers['Building'][i].name.charCodeAt(j) -65; + if (startlet>25) startlet-=32; //select small letters (which shouldn't even be there) + + if ((startlet==96)||(startlet==128)) startlet=0; //catch Á + if (startlet==104) startlet=4; //catch É + if (startlet==108) startlet=8; //catch Í + + numplaces=tables[String.fromCharCode(startlet+65)].length; + tables[String.fromCharCode(startlet+65)].push(new place(markers['Building'][i].name,i,markers['Building'][i].info)); + tables[String.fromCharCode(startlet+65)][numplaces].building=i; //resolve reference to building array + } + + } + //sort results alphabetically + for (i=0;i<26;i++) { + letter=String.fromCharCode(i+65); + tables[letter].sort(function(a,b) { if (a.name"+letter+" "; + } + menu+=""; + document.getElementById("searchoptions").innerHTML=menu; + //action='map.php' + menu="
"; + document.getElementById("quicklinkswrap").innerHTML=menu; +} +//----------------------------------------------------------------------------------Editing markers while authoring +function setMarkerPosition() { + if (this.type=="Building") { + $.ajax({ + url:"setMarkerPos.php", + data: "table="+this.type+"&id="+this.id+"&lat="+this.getPosition().lat()+"&lng="+this.getPosition().lng()+"&google_coords=1" + }); + this.setIcon(new G.MarkerImage("http://maps.google.com/mapfiles/marker_orange.png") ); + } + else { + $.ajax({ + url:"setMarkerPos.php", + data: "table="+this.type+"&id="+this.id+"&lat="+this.getPosition().lat()+"&lng="+this.getPosition().lng() + }); + } +} +function displayMarkerInfo(){ + if (this.type=="Building") document.getElementById("info").innerHTML=this.id+": "+this.name; + else document.getElementById("info").innerHTML=this.id; +} +//----------------------------------------------------------------------------------Interaction handlers +function shadowbox(n) { + Shadowbox.open({content:"./photos/"+n+".jpg",player: "img",title:markers['Building'][n].name}); +} +function onsearch(query) { + tables["search"]=[]; + var foundbuildings=new Array(); + fb=0; + for (var i=0;i<26;i++) { + //console.log("checking "+String.fromCharCode(i+65)); + for (j in tables[String.fromCharCode(i+65)]) { + + + if (tables[String.fromCharCode(i+65)][j]!=undefined) { + //console.log("checking "+j+": "+tables[String.fromCharCode(i+65)][j].name); + + if ("name" in tables[String.fromCharCode(i+65)][j]) { + if (tables[String.fromCharCode(i+65)][j].name.toLowerCase().indexOf(query.toLowerCase())>-1) { + tables["search"].push(tables[String.fromCharCode(i+65)][j]); + if (foundbuildings[tables[String.fromCharCode(i+65)][j].building]!="1") fb++; + foundbuildings[tables[String.fromCharCode(i+65)][j].building]="1"; + } + } + + } + + } + } + //auto-open if 1 search result + if (fb==1) { + clearmarkers(); + markers["Building"][tables["search"][0].building].show(true,tables["search"][0]); + } + tables["search"].screenname=query; + tables["search"].sort(function(a,b) {if (a.name"+tables[type][i].name+""; + } + content+=""; + document.getElementById("searchresults").innerHTML=content; + if(do_menu_flag) { + resize_map_and_results(); + } + else { + do_menu_flag = true; + } + if (DEBUG) alert(content); + } +} +function purgeInfoWindow() { + if (InfoWindow) { + //console.log("closing infowindow"); + InfoWindow.close(); + InfoWindow=undefined; + } +} +function clearmarkers() { + for (i in markers) { + for (j in markers[i]) { + if (markers[i][j].name) markers[i][j].hide; + } + } +} +function directions(lat,lng,place){ + document.getElementById("searchresulttitle").innerHTML="

From Trinity College to "+place+"

"; + document.getElementById("searchresults").innerHTML=""; + var request = { + origin:new G.LatLng(53.3445,-6.259), + destination:new G.LatLng(lat,lng), + travelMode: google.maps.DirectionsTravelMode.DRIVING + }; + directionsDisplay.setPanel(document.getElementById("searchresults")); + directionsService.route(request, function(response, status) { + if (status == G.DirectionsStatus.OK) { + directionsDisplay.setDirections(response); + } + }); +} +//----------------------------------------------------------------------------------misc utils, legacy ajax stuff to bypass TCD fuzzy filename filter +//Equivalent of getBoundsZoomLevel() in gmaps api 3 +/** +* Returns the zoom level at which the given rectangular region fits in the map view. +* The zoom level is computed for the currently selected map type. +* @param {google.maps.Map} map +* @param {google.maps.LatLngBounds} bounds +* @return {Number} zoom level +**/ +function getZoomByBounds( map, bounds ){ + var MAX_ZOOM = map.mapTypes.get( map.getMapTypeId() ).maxZoom || 21 ; + var MIN_ZOOM = map.mapTypes.get( map.getMapTypeId() ).minZoom || 0 ; + + var ne= map.getProjection().fromLatLngToPoint( bounds.getNorthEast() ); + var sw= map.getProjection().fromLatLngToPoint( bounds.getSouthWest() ); + + var worldCoordWidth = Math.abs(ne.x-sw.x); + var worldCoordHeight = Math.abs(ne.y-sw.y); + + //Fit padding in pixels + var FIT_PAD = 40; + + for( var zoom = MAX_ZOOM; zoom >= MIN_ZOOM; --zoom ){ + if( worldCoordWidth*(1< 127) && (c < 2048)) { + utftext += String.fromCharCode((c >> 6) | 192); + utftext += String.fromCharCode((c & 63) | 128); + } + else { + utftext += String.fromCharCode((c >> 12) | 224); + utftext += String.fromCharCode(((c >> 6) & 63) | 128); + utftext += String.fromCharCode((c & 63) | 128); + } + + } + + return escape(utftext); +} +function httpexists(url) { + exists=false; + http.open("GET",'httpexists-proxy.php?httpexistsurl=' + url, false); + //http.open("GET", url, false); + http.send(null); + if (http.status == 200) { + exists=true; + } + return exists; +} +function getHTTPObject() { + var xmlhttp; + if (!xmlhttp && typeof XMLHttpRequest != 'undefined') { + try { + xmlhttp = new XMLHttpRequest(); + } catch (e) { + xmlhttp = false; + } + } + return xmlhttp; +} + diff --git a/map.php b/map.php new file mode 100755 index 0000000..d10ae24 --- /dev/null +++ b/map.php @@ -0,0 +1,116 @@ + + + +College Maps : Trinity College Dublin + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+

Trinity College Dublin

+

Skip to main content.

+ +

Core links

+ +
+ +
+
+

College Maps

+ + +
+
+ + +
+
+
+
+
+
+
+ +
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+

Last updated 25 November 2009 by College Maps.

+
+ +
+ + diff --git a/map_prepare.php b/map_prepare.php new file mode 100755 index 0000000..288f104 --- /dev/null +++ b/map_prepare.php @@ -0,0 +1,19 @@ + + + + \ No newline at end of file diff --git a/mapedit.php b/mapedit.php new file mode 100755 index 0000000..4f268b7 --- /dev/null +++ b/mapedit.php @@ -0,0 +1,26 @@ + + + + + + + + + + + +
> +
> + + diff --git a/maps-extra.js b/maps-extra.js new file mode 100755 index 0000000..e6cc7e1 --- /dev/null +++ b/maps-extra.js @@ -0,0 +1,165 @@ +// Version 1.3 20081218.1405 + +//var show_parking_warning=true; + +// Start up Shadowbox. +Shadowbox.init({ + players: ['img', 'qt','html'] // See http://www.shadowbox-js.com/options.html#players for more players. +}); + +$(document).ready(function() { + + // Set the default message to be displayed in the search box. + var search_query_message = 'Search the map' + // The following is the mechanics for the search box to show and hide the default message. + if ($('#query').attr('value') != search_query_message) + { + if (search_posted != '') + { + $('#query').attr('value', search_posted); + } + else + { + $('#query').attr('value', search_query_message); + } + } + $('#query').focus(function() { + if ($(this).attr('value') == search_query_message) + { + $(this).attr('value', ''); + } + }); + $('#query').blur(function() { + if (!$(this).attr('value') || $(this).attr('value').replace(/^\s*/, "").replace(/\s*$/, "") == '') + { + $(this).attr('value', search_query_message); + } + }); + // Set the action when the search box form is submitted. + if ($('#headerform')) { + $('#headerform').submit(function() { + var el = document.getElementById('query'); + onsearch(el.value); + return submit_the_query_form; + }); + }; + // Set the default height for the map. + if ($('#map') && parseInt($('#map').css('height'), 10) < 201) { + $('#map').css('height', '200px'); + }; + + +}); +// +function callback_for_resizing() { + + // Chuck the map icons in and prepare the events. + if ($('#mapicons')) + { + // Display the map icon buttons.
  • Parking
  • + $('#mapicons').html('

    Map toggles

    '); + // Set the click event. + $('#mapicons li').click(function() { + if ($(this).attr('id')=="Parking"&&show_parking_warning) { + Shadowbox.open({ + content: "
    There is no public parking available in Trinity; parking is permit or by arrangement only.

    The icons displayed show the locations of enabled parking for those with a permit or prior arrangement to park on the grounds.
    ", + player: "html", + title: "Parking Notice", + height: 350, + width: 360 + }); + show_parking_warning=false; + } + show_markers($(this).attr('id')); + if (markers[$(this).attr('id')].visible) + { + $(this).attr('class', 'selected'); + } + else + { + $(this).attr('class', ''); + } + return false; + }); + // Set the key event. + $('#mapicons li').keyup(function(event) { + if (event.keyCode == 13 || event.keyCode == 32) // Return/enter or space. + { + show_markers($(this).attr('id')); + if (markers[$(this).attr('id')].visible) + { + $(this).attr('class', 'selected'); + } + else + { + $(this).attr('class', ''); + } + return false; + } + }); + } + // Get the element mapwrap and apply the class js_active. This will give a means for different styles to be applied when Javascript is off. + var mapwrap = $('.wrap'); + mapwrap[0].className = mapwrap[0].className + ' js_active'; + // Do the same but with the searchoptions element. + //var mapwrap = document.getElementById('searchoptions'); + //mapwrap.parentNode.className += ' js_active'; + resize_map_and_results(); + $(window).resize(function() { + resize_map_and_results(); + }); + // Check if the POST search variable was passed to Javascript. + if (search_posted != '') + { + // Update the search results. + onsearch(search_posted); + } + // Check if the POST quicklinks variable was passed to Javascript. + if (quicklinks_posted != '') + { + // Update the search results. + do_menu(quicklinks_posted); + } +} +function resize_map_and_results() { + // Fix mapicons and searchresulttitle so that they have the same height by adding padding to the top. + if ($('#searchresulttitle') && $('#map') && $('#mapicons')) + { + var diff = $('#searchresults').offset().top - $('#map').offset().top; + var searchresulttitle_padding = parseFloat($('#searchresulttitle').css('padding-top'), 10); + var mapicons_padding = parseFloat($('#mapicons').css('padding-top'), 10); + if (diff > 0) + { + // Increase the height of mapicons by adding padding to the top. + mapicons_padding = mapicons_padding + diff; + } + else if (diff < 0) + { + searchresulttitle_padding = searchresulttitle_padding - diff; + } + diff = 0; + if (searchresulttitle_padding > 0 && mapicons_padding > 0) + { + diff = Math.min(searchresulttitle_padding, mapicons_padding); + } + $('#mapicons').css('padding-top', mapicons_padding - diff + 'px'); + $('#searchresulttitle').css('padding-top', searchresulttitle_padding - diff + 'px'); + } + // Fix the vertical dimensions of the map. + if ($('#searchresults') && $('#map')) + { + var diff = Math.abs($(window).height() - $('#map').offset().top - 10); // The 10 is the base padding value used throughout the design. + if (diff < 400) { + diff = 400; + } + $('#map').css('height', diff + 'px'); + $('#searchresults').css('height', diff + 2 + 'px'); // The 2 is a bit random but adjusts the bottom of the results to match the map. + } + + map.setCenter(STARTPOS, 17); +} +function MM_jumpMenu(targ,selObj,restore){ //v3.0 + eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'"); + if (restore) selObj.selectedIndex=0; +} + diff --git a/photos/1.jpg b/photos/1.jpg new file mode 100755 index 0000000..6edcd93 Binary files /dev/null and b/photos/1.jpg differ diff --git a/photos/12.jpg b/photos/12.jpg new file mode 100755 index 0000000..f656477 Binary files /dev/null and b/photos/12.jpg differ diff --git a/photos/124.jpg b/photos/124.jpg new file mode 100755 index 0000000..b61cea1 Binary files /dev/null and b/photos/124.jpg differ diff --git a/photos/13.jpg b/photos/13.jpg new file mode 100755 index 0000000..4a9ed73 Binary files /dev/null and b/photos/13.jpg differ diff --git a/photos/14.jpg b/photos/14.jpg new file mode 100755 index 0000000..40cf346 Binary files /dev/null and b/photos/14.jpg differ diff --git a/photos/15.jpg b/photos/15.jpg new file mode 100755 index 0000000..40608a5 Binary files /dev/null and b/photos/15.jpg differ diff --git a/photos/16.jpg b/photos/16.jpg new file mode 100755 index 0000000..d93a413 Binary files /dev/null and b/photos/16.jpg differ diff --git a/photos/17.jpg b/photos/17.jpg new file mode 100755 index 0000000..7121ea0 Binary files /dev/null and b/photos/17.jpg differ diff --git a/photos/18.jpg b/photos/18.jpg new file mode 100755 index 0000000..44bcfe0 Binary files /dev/null and b/photos/18.jpg differ diff --git a/photos/181.jpg b/photos/181.jpg new file mode 100755 index 0000000..11a934e Binary files /dev/null and b/photos/181.jpg differ diff --git a/photos/19.jpg b/photos/19.jpg new file mode 100755 index 0000000..855f646 Binary files /dev/null and b/photos/19.jpg differ diff --git a/photos/194.jpg b/photos/194.jpg new file mode 100755 index 0000000..5904da4 Binary files /dev/null and b/photos/194.jpg differ diff --git a/photos/198.jpg b/photos/198.jpg new file mode 100755 index 0000000..2da5aca Binary files /dev/null and b/photos/198.jpg differ diff --git a/photos/199.jpg b/photos/199.jpg new file mode 100755 index 0000000..d771043 Binary files /dev/null and b/photos/199.jpg differ diff --git a/photos/200.jpg b/photos/200.jpg new file mode 100755 index 0000000..99f2c7f Binary files /dev/null and b/photos/200.jpg differ diff --git a/photos/211.jpg b/photos/211.jpg new file mode 100755 index 0000000..3793493 Binary files /dev/null and b/photos/211.jpg differ diff --git a/photos/22.jpg b/photos/22.jpg new file mode 100755 index 0000000..8ada302 Binary files /dev/null and b/photos/22.jpg differ diff --git a/photos/23.jpg b/photos/23.jpg new file mode 100755 index 0000000..393634e Binary files /dev/null and b/photos/23.jpg differ diff --git a/photos/233.jpg b/photos/233.jpg new file mode 100755 index 0000000..73b4711 Binary files /dev/null and b/photos/233.jpg differ diff --git a/photos/243.jpg b/photos/243.jpg new file mode 100755 index 0000000..8c19902 Binary files /dev/null and b/photos/243.jpg differ diff --git a/photos/246.jpg b/photos/246.jpg new file mode 100755 index 0000000..2f7d10f Binary files /dev/null and b/photos/246.jpg differ diff --git a/photos/249.jpg b/photos/249.jpg new file mode 100755 index 0000000..4eea705 Binary files /dev/null and b/photos/249.jpg differ diff --git a/photos/250.jpg b/photos/250.jpg new file mode 100755 index 0000000..07969a3 Binary files /dev/null and b/photos/250.jpg differ diff --git a/photos/253.jpg b/photos/253.jpg new file mode 100755 index 0000000..829fc31 Binary files /dev/null and b/photos/253.jpg differ diff --git a/photos/254.jpg b/photos/254.jpg new file mode 100755 index 0000000..11b9b01 Binary files /dev/null and b/photos/254.jpg differ diff --git a/photos/32.jpg b/photos/32.jpg new file mode 100755 index 0000000..1460a66 Binary files /dev/null and b/photos/32.jpg differ diff --git a/photos/40.jpg b/photos/40.jpg new file mode 100755 index 0000000..19e1805 Binary files /dev/null and b/photos/40.jpg differ diff --git a/photos/54.jpg b/photos/54.jpg new file mode 100755 index 0000000..e166ed8 Binary files /dev/null and b/photos/54.jpg differ diff --git a/photos/55.jpg b/photos/55.jpg new file mode 100755 index 0000000..c73a787 Binary files /dev/null and b/photos/55.jpg differ diff --git a/photos/56.jpg b/photos/56.jpg new file mode 100755 index 0000000..ca2c4d7 Binary files /dev/null and b/photos/56.jpg differ diff --git a/photos/57.jpg b/photos/57.jpg new file mode 100755 index 0000000..129611d Binary files /dev/null and b/photos/57.jpg differ diff --git a/photos/58.jpg b/photos/58.jpg new file mode 100755 index 0000000..bc89f0c Binary files /dev/null and b/photos/58.jpg differ diff --git a/photos/59.jpg b/photos/59.jpg new file mode 100755 index 0000000..7f419f2 Binary files /dev/null and b/photos/59.jpg differ diff --git a/photos/61.jpg b/photos/61.jpg new file mode 100755 index 0000000..8257824 Binary files /dev/null and b/photos/61.jpg differ diff --git a/photos/67.jpg b/photos/67.jpg new file mode 100755 index 0000000..06a5a10 Binary files /dev/null and b/photos/67.jpg differ diff --git a/photos/68.jpg b/photos/68.jpg new file mode 100755 index 0000000..2d0cb7d Binary files /dev/null and b/photos/68.jpg differ diff --git a/photos/7.jpg b/photos/7.jpg new file mode 100755 index 0000000..23fa39d Binary files /dev/null and b/photos/7.jpg differ diff --git a/photos/70.jpg b/photos/70.jpg new file mode 100755 index 0000000..5348ab8 Binary files /dev/null and b/photos/70.jpg differ diff --git a/photos/71.jpg b/photos/71.jpg new file mode 100755 index 0000000..604ed00 Binary files /dev/null and b/photos/71.jpg differ diff --git a/photos/73.jpg b/photos/73.jpg new file mode 100755 index 0000000..7b934ef Binary files /dev/null and b/photos/73.jpg differ diff --git a/photos/74.jpg b/photos/74.jpg new file mode 100755 index 0000000..f8d6fa7 Binary files /dev/null and b/photos/74.jpg differ diff --git a/photos/75.jpg b/photos/75.jpg new file mode 100755 index 0000000..9cb561a Binary files /dev/null and b/photos/75.jpg differ diff --git a/photos/8.jpg b/photos/8.jpg new file mode 100755 index 0000000..a1a8011 Binary files /dev/null and b/photos/8.jpg differ diff --git a/photos/81.jpg b/photos/81.jpg new file mode 100755 index 0000000..df407be Binary files /dev/null and b/photos/81.jpg differ diff --git a/photos/82.jpg b/photos/82.jpg new file mode 100755 index 0000000..5040981 Binary files /dev/null and b/photos/82.jpg differ diff --git a/photos/83.jpg b/photos/83.jpg new file mode 100755 index 0000000..afea5dc Binary files /dev/null and b/photos/83.jpg differ diff --git a/photos/9.jpg b/photos/9.jpg new file mode 100755 index 0000000..cf2618b Binary files /dev/null and b/photos/9.jpg differ diff --git a/photos/_notes/dwsync.xml b/photos/_notes/dwsync.xml new file mode 100755 index 0000000..aa4ef9a --- /dev/null +++ b/photos/_notes/dwsync.xml @@ -0,0 +1,50 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/photos/small/1.jpg b/photos/small/1.jpg new file mode 100755 index 0000000..472d4cc Binary files /dev/null and b/photos/small/1.jpg differ diff --git a/photos/small/12.jpg b/photos/small/12.jpg new file mode 100755 index 0000000..aa638ec Binary files /dev/null and b/photos/small/12.jpg differ diff --git a/photos/small/124.jpg b/photos/small/124.jpg new file mode 100755 index 0000000..2366cce Binary files /dev/null and b/photos/small/124.jpg differ diff --git a/photos/small/13.jpg b/photos/small/13.jpg new file mode 100755 index 0000000..8a27eff Binary files /dev/null and b/photos/small/13.jpg differ diff --git a/photos/small/14.jpg b/photos/small/14.jpg new file mode 100755 index 0000000..4abba50 Binary files /dev/null and b/photos/small/14.jpg differ diff --git a/photos/small/15.jpg b/photos/small/15.jpg new file mode 100755 index 0000000..c2bbcea Binary files /dev/null and b/photos/small/15.jpg differ diff --git a/photos/small/16.jpg b/photos/small/16.jpg new file mode 100755 index 0000000..d08d6b5 Binary files /dev/null and b/photos/small/16.jpg differ diff --git a/photos/small/17.jpg b/photos/small/17.jpg new file mode 100755 index 0000000..9bb4c7b Binary files /dev/null and b/photos/small/17.jpg differ diff --git a/photos/small/18.jpg b/photos/small/18.jpg new file mode 100755 index 0000000..3f5acf5 Binary files /dev/null and b/photos/small/18.jpg differ diff --git a/photos/small/181.jpg b/photos/small/181.jpg new file mode 100755 index 0000000..2e8ca01 Binary files /dev/null and b/photos/small/181.jpg differ diff --git a/photos/small/19.jpg b/photos/small/19.jpg new file mode 100755 index 0000000..d9ad351 Binary files /dev/null and b/photos/small/19.jpg differ diff --git a/photos/small/194.jpg b/photos/small/194.jpg new file mode 100755 index 0000000..3833e6c Binary files /dev/null and b/photos/small/194.jpg differ diff --git a/photos/small/198.jpg b/photos/small/198.jpg new file mode 100755 index 0000000..451812a Binary files /dev/null and b/photos/small/198.jpg differ diff --git a/photos/small/199.jpg b/photos/small/199.jpg new file mode 100755 index 0000000..1f396ac Binary files /dev/null and b/photos/small/199.jpg differ diff --git a/photos/small/200.jpg b/photos/small/200.jpg new file mode 100755 index 0000000..cb7f2f1 Binary files /dev/null and b/photos/small/200.jpg differ diff --git a/photos/small/211.jpg b/photos/small/211.jpg new file mode 100755 index 0000000..a9dcff9 Binary files /dev/null and b/photos/small/211.jpg differ diff --git a/photos/small/22.jpg b/photos/small/22.jpg new file mode 100755 index 0000000..a570afe Binary files /dev/null and b/photos/small/22.jpg differ diff --git a/photos/small/23.jpg b/photos/small/23.jpg new file mode 100755 index 0000000..1ffb543 Binary files /dev/null and b/photos/small/23.jpg differ diff --git a/photos/small/233.jpg b/photos/small/233.jpg new file mode 100755 index 0000000..ba72d72 Binary files /dev/null and b/photos/small/233.jpg differ diff --git a/photos/small/243.jpg b/photos/small/243.jpg new file mode 100755 index 0000000..ef4dd1d Binary files /dev/null and b/photos/small/243.jpg differ diff --git a/photos/small/246.jpg b/photos/small/246.jpg new file mode 100755 index 0000000..3f4cf08 Binary files /dev/null and b/photos/small/246.jpg differ diff --git a/photos/small/249.jpg b/photos/small/249.jpg new file mode 100755 index 0000000..09ca872 Binary files /dev/null and b/photos/small/249.jpg differ diff --git a/photos/small/250.jpg b/photos/small/250.jpg new file mode 100755 index 0000000..07a1d98 Binary files /dev/null and b/photos/small/250.jpg differ diff --git a/photos/small/253.jpg b/photos/small/253.jpg new file mode 100755 index 0000000..fb10a60 Binary files /dev/null and b/photos/small/253.jpg differ diff --git a/photos/small/254.jpg b/photos/small/254.jpg new file mode 100755 index 0000000..3820916 Binary files /dev/null and b/photos/small/254.jpg differ diff --git a/photos/small/32.jpg b/photos/small/32.jpg new file mode 100755 index 0000000..9e6f977 Binary files /dev/null and b/photos/small/32.jpg differ diff --git a/photos/small/40.jpg b/photos/small/40.jpg new file mode 100755 index 0000000..8fdd805 Binary files /dev/null and b/photos/small/40.jpg differ diff --git a/photos/small/54.jpg b/photos/small/54.jpg new file mode 100755 index 0000000..977c38e Binary files /dev/null and b/photos/small/54.jpg differ diff --git a/photos/small/55.jpg b/photos/small/55.jpg new file mode 100755 index 0000000..c26f273 Binary files /dev/null and b/photos/small/55.jpg differ diff --git a/photos/small/56.jpg b/photos/small/56.jpg new file mode 100755 index 0000000..ab270c3 Binary files /dev/null and b/photos/small/56.jpg differ diff --git a/photos/small/57.jpg b/photos/small/57.jpg new file mode 100755 index 0000000..86bad06 Binary files /dev/null and b/photos/small/57.jpg differ diff --git a/photos/small/58.jpg b/photos/small/58.jpg new file mode 100755 index 0000000..d6d85f4 Binary files /dev/null and b/photos/small/58.jpg differ diff --git a/photos/small/59.jpg b/photos/small/59.jpg new file mode 100755 index 0000000..d7cb5e1 Binary files /dev/null and b/photos/small/59.jpg differ diff --git a/photos/small/61.jpg b/photos/small/61.jpg new file mode 100755 index 0000000..6f07e8e Binary files /dev/null and b/photos/small/61.jpg differ diff --git a/photos/small/67.jpg b/photos/small/67.jpg new file mode 100755 index 0000000..056f9d6 Binary files /dev/null and b/photos/small/67.jpg differ diff --git a/photos/small/68.jpg b/photos/small/68.jpg new file mode 100755 index 0000000..33c46f7 Binary files /dev/null and b/photos/small/68.jpg differ diff --git a/photos/small/7.jpg b/photos/small/7.jpg new file mode 100755 index 0000000..bf2997a Binary files /dev/null and b/photos/small/7.jpg differ diff --git a/photos/small/70.jpg b/photos/small/70.jpg new file mode 100755 index 0000000..cc62666 Binary files /dev/null and b/photos/small/70.jpg differ diff --git a/photos/small/71.jpg b/photos/small/71.jpg new file mode 100755 index 0000000..50dbbfb Binary files /dev/null and b/photos/small/71.jpg differ diff --git a/photos/small/73.jpg b/photos/small/73.jpg new file mode 100755 index 0000000..49acfea Binary files /dev/null and b/photos/small/73.jpg differ diff --git a/photos/small/74.jpg b/photos/small/74.jpg new file mode 100755 index 0000000..44444a7 Binary files /dev/null and b/photos/small/74.jpg differ diff --git a/photos/small/75.jpg b/photos/small/75.jpg new file mode 100755 index 0000000..279852c Binary files /dev/null and b/photos/small/75.jpg differ diff --git a/photos/small/8.jpg b/photos/small/8.jpg new file mode 100755 index 0000000..65c0e6e Binary files /dev/null and b/photos/small/8.jpg differ diff --git a/photos/small/81.jpg b/photos/small/81.jpg new file mode 100755 index 0000000..c32fad3 Binary files /dev/null and b/photos/small/81.jpg differ diff --git a/photos/small/82.jpg b/photos/small/82.jpg new file mode 100755 index 0000000..cf05026 Binary files /dev/null and b/photos/small/82.jpg differ diff --git a/photos/small/83.jpg b/photos/small/83.jpg new file mode 100755 index 0000000..c9e7398 Binary files /dev/null and b/photos/small/83.jpg differ diff --git a/photos/small/9.jpg b/photos/small/9.jpg new file mode 100755 index 0000000..edff912 Binary files /dev/null and b/photos/small/9.jpg differ diff --git a/photos/small/_notes/dwsync.xml b/photos/small/_notes/dwsync.xml new file mode 100755 index 0000000..ec5b039 --- /dev/null +++ b/photos/small/_notes/dwsync.xml @@ -0,0 +1,50 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/photos/thumbs/1.jpg b/photos/thumbs/1.jpg new file mode 100755 index 0000000..3d89d9f Binary files /dev/null and b/photos/thumbs/1.jpg differ diff --git a/photos/thumbs/12.jpg b/photos/thumbs/12.jpg new file mode 100755 index 0000000..d460b98 Binary files /dev/null and b/photos/thumbs/12.jpg differ diff --git a/photos/thumbs/124.jpg b/photos/thumbs/124.jpg new file mode 100755 index 0000000..22c0c90 Binary files /dev/null and b/photos/thumbs/124.jpg differ diff --git a/photos/thumbs/13.jpg b/photos/thumbs/13.jpg new file mode 100755 index 0000000..0d5b4ae Binary files /dev/null and b/photos/thumbs/13.jpg differ diff --git a/photos/thumbs/14.jpg b/photos/thumbs/14.jpg new file mode 100755 index 0000000..8a346d8 Binary files /dev/null and b/photos/thumbs/14.jpg differ diff --git a/photos/thumbs/15.jpg b/photos/thumbs/15.jpg new file mode 100755 index 0000000..8200e24 Binary files /dev/null and b/photos/thumbs/15.jpg differ diff --git a/photos/thumbs/16.jpg b/photos/thumbs/16.jpg new file mode 100755 index 0000000..d0fee4b Binary files /dev/null and b/photos/thumbs/16.jpg differ diff --git a/photos/thumbs/17.jpg b/photos/thumbs/17.jpg new file mode 100755 index 0000000..0722e93 Binary files /dev/null and b/photos/thumbs/17.jpg differ diff --git a/photos/thumbs/18.jpg b/photos/thumbs/18.jpg new file mode 100755 index 0000000..496dbc8 Binary files /dev/null and b/photos/thumbs/18.jpg differ diff --git a/photos/thumbs/181.jpg b/photos/thumbs/181.jpg new file mode 100755 index 0000000..7585a97 Binary files /dev/null and b/photos/thumbs/181.jpg differ diff --git a/photos/thumbs/19.jpg b/photos/thumbs/19.jpg new file mode 100755 index 0000000..4a15bc8 Binary files /dev/null and b/photos/thumbs/19.jpg differ diff --git a/photos/thumbs/194.jpg b/photos/thumbs/194.jpg new file mode 100755 index 0000000..6336264 Binary files /dev/null and b/photos/thumbs/194.jpg differ diff --git a/photos/thumbs/198.jpg b/photos/thumbs/198.jpg new file mode 100755 index 0000000..89f00e3 Binary files /dev/null and b/photos/thumbs/198.jpg differ diff --git a/photos/thumbs/199.jpg b/photos/thumbs/199.jpg new file mode 100755 index 0000000..6c2b91c Binary files /dev/null and b/photos/thumbs/199.jpg differ diff --git a/photos/thumbs/200.jpg b/photos/thumbs/200.jpg new file mode 100755 index 0000000..c0afdfc Binary files /dev/null and b/photos/thumbs/200.jpg differ diff --git a/photos/thumbs/211.jpg b/photos/thumbs/211.jpg new file mode 100755 index 0000000..11d9e26 Binary files /dev/null and b/photos/thumbs/211.jpg differ diff --git a/photos/thumbs/22.jpg b/photos/thumbs/22.jpg new file mode 100755 index 0000000..407f1c2 Binary files /dev/null and b/photos/thumbs/22.jpg differ diff --git a/photos/thumbs/23.jpg b/photos/thumbs/23.jpg new file mode 100755 index 0000000..f66113c Binary files /dev/null and b/photos/thumbs/23.jpg differ diff --git a/photos/thumbs/233.jpg b/photos/thumbs/233.jpg new file mode 100755 index 0000000..107876d Binary files /dev/null and b/photos/thumbs/233.jpg differ diff --git a/photos/thumbs/243.jpg b/photos/thumbs/243.jpg new file mode 100755 index 0000000..8e8e6a3 Binary files /dev/null and b/photos/thumbs/243.jpg differ diff --git a/photos/thumbs/246.jpg b/photos/thumbs/246.jpg new file mode 100755 index 0000000..70ba95c Binary files /dev/null and b/photos/thumbs/246.jpg differ diff --git a/photos/thumbs/249.jpg b/photos/thumbs/249.jpg new file mode 100755 index 0000000..939bc2b Binary files /dev/null and b/photos/thumbs/249.jpg differ diff --git a/photos/thumbs/250.jpg b/photos/thumbs/250.jpg new file mode 100755 index 0000000..689a950 Binary files /dev/null and b/photos/thumbs/250.jpg differ diff --git a/photos/thumbs/253.jpg b/photos/thumbs/253.jpg new file mode 100755 index 0000000..4ea3b04 Binary files /dev/null and b/photos/thumbs/253.jpg differ diff --git a/photos/thumbs/254.jpg b/photos/thumbs/254.jpg new file mode 100755 index 0000000..02709f7 Binary files /dev/null and b/photos/thumbs/254.jpg differ diff --git a/photos/thumbs/32.jpg b/photos/thumbs/32.jpg new file mode 100755 index 0000000..d52d4e6 Binary files /dev/null and b/photos/thumbs/32.jpg differ diff --git a/photos/thumbs/40.jpg b/photos/thumbs/40.jpg new file mode 100755 index 0000000..28fda86 Binary files /dev/null and b/photos/thumbs/40.jpg differ diff --git a/photos/thumbs/54.jpg b/photos/thumbs/54.jpg new file mode 100755 index 0000000..a2f18f6 Binary files /dev/null and b/photos/thumbs/54.jpg differ diff --git a/photos/thumbs/55.jpg b/photos/thumbs/55.jpg new file mode 100755 index 0000000..be2e846 Binary files /dev/null and b/photos/thumbs/55.jpg differ diff --git a/photos/thumbs/56.jpg b/photos/thumbs/56.jpg new file mode 100755 index 0000000..7dde0c3 Binary files /dev/null and b/photos/thumbs/56.jpg differ diff --git a/photos/thumbs/57.jpg b/photos/thumbs/57.jpg new file mode 100755 index 0000000..e5d72c1 Binary files /dev/null and b/photos/thumbs/57.jpg differ diff --git a/photos/thumbs/58.jpg b/photos/thumbs/58.jpg new file mode 100755 index 0000000..b952c26 Binary files /dev/null and b/photos/thumbs/58.jpg differ diff --git a/photos/thumbs/59.jpg b/photos/thumbs/59.jpg new file mode 100755 index 0000000..f8a8c08 Binary files /dev/null and b/photos/thumbs/59.jpg differ diff --git a/photos/thumbs/61.jpg b/photos/thumbs/61.jpg new file mode 100755 index 0000000..d9a8377 Binary files /dev/null and b/photos/thumbs/61.jpg differ diff --git a/photos/thumbs/67.jpg b/photos/thumbs/67.jpg new file mode 100755 index 0000000..aa1cd86 Binary files /dev/null and b/photos/thumbs/67.jpg differ diff --git a/photos/thumbs/68.jpg b/photos/thumbs/68.jpg new file mode 100755 index 0000000..0c29d3d Binary files /dev/null and b/photos/thumbs/68.jpg differ diff --git a/photos/thumbs/7.jpg b/photos/thumbs/7.jpg new file mode 100755 index 0000000..3b6df29 Binary files /dev/null and b/photos/thumbs/7.jpg differ diff --git a/photos/thumbs/70.jpg b/photos/thumbs/70.jpg new file mode 100755 index 0000000..a2c7a2a Binary files /dev/null and b/photos/thumbs/70.jpg differ diff --git a/photos/thumbs/71.jpg b/photos/thumbs/71.jpg new file mode 100755 index 0000000..138a31b Binary files /dev/null and b/photos/thumbs/71.jpg differ diff --git a/photos/thumbs/73.jpg b/photos/thumbs/73.jpg new file mode 100755 index 0000000..cf0b031 Binary files /dev/null and b/photos/thumbs/73.jpg differ diff --git a/photos/thumbs/74.jpg b/photos/thumbs/74.jpg new file mode 100755 index 0000000..3eef42b Binary files /dev/null and b/photos/thumbs/74.jpg differ diff --git a/photos/thumbs/75.jpg b/photos/thumbs/75.jpg new file mode 100755 index 0000000..97fb219 Binary files /dev/null and b/photos/thumbs/75.jpg differ diff --git a/photos/thumbs/8.jpg b/photos/thumbs/8.jpg new file mode 100755 index 0000000..eb9db6f Binary files /dev/null and b/photos/thumbs/8.jpg differ diff --git a/photos/thumbs/81.jpg b/photos/thumbs/81.jpg new file mode 100755 index 0000000..ec0f2ff Binary files /dev/null and b/photos/thumbs/81.jpg differ diff --git a/photos/thumbs/82.jpg b/photos/thumbs/82.jpg new file mode 100755 index 0000000..14a378e Binary files /dev/null and b/photos/thumbs/82.jpg differ diff --git a/photos/thumbs/83.jpg b/photos/thumbs/83.jpg new file mode 100755 index 0000000..948ddc8 Binary files /dev/null and b/photos/thumbs/83.jpg differ diff --git a/photos/thumbs/9.jpg b/photos/thumbs/9.jpg new file mode 100755 index 0000000..fb054e8 Binary files /dev/null and b/photos/thumbs/9.jpg differ diff --git a/photos/thumbs/_notes/dwsync.xml b/photos/thumbs/_notes/dwsync.xml new file mode 100755 index 0000000..d47f7b0 --- /dev/null +++ b/photos/thumbs/_notes/dwsync.xml @@ -0,0 +1,50 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/setMarkerPos.php b/setMarkerPos.php new file mode 100755 index 0000000..7ac21df --- /dev/null +++ b/setMarkerPos.php @@ -0,0 +1,17 @@ + \ No newline at end of file diff --git a/styles-working.css b/styles-working.css new file mode 100755 index 0000000..95902e6 --- /dev/null +++ b/styles-working.css @@ -0,0 +1,83 @@ +#map_info {font-size: 0.9em;width: 330px;} +#map_info img {padding:0;} + +#map_info h4 {font-size: 1.2em;font-weight: bold;font-family: Arial, Helvetica, sans-serif;background-color: #29a7c2;color: #FFFFFF;margin:0 0 0 0;padding:0 3px 2px 4px;} +#map_info h4 a {display:block;color:#fff;} + +#map_building {font-size: 0.9em;width: 330px;height:auto!important;min-height:170px;height:170px;} + +#map_building h4 {font-size: 1.2em;text-transform: uppercase;font-weight: bold;font-family: Arial, Helvetica, sans-serif;background-color: #29a7c2;color: #FFFFFF;margin:0 16px 3px 0;padding:3px 3px 1px 4px;} +#map_building h5 {font-size: 1.1em;font-weight: bold;font-style:normal;font-family: Arial, Helvetica, sans-serif;background-color: #FFFFFF;color: #000000;margin:0;padding:0;} +#map_building h6 {font-size: 1.2em;font-weight: normal;font-style:oblique;font-family: Arial, Helvetica, sans-serif;background-color: #FFFFFF;color: #000000;margin:0 0 0 0;padding:0 3px 1px 3px;} +#map_building h7 {font-size: 1.2em;font-weight: normal;font-family: Arial, Helvetica, sans-serif;background-color: #FFFFFF;color: #000000;margin:0 0 0 0;padding:0 3px 1px 3px;} + +#map_building_inner {margin:0px 16px 0 0;padding:0 0 6px 0;height: 110px;display: block;overflow: auto;overflow-x: hidden;/*(hide horizontal scroll bar)position: absolute;top: 140px;right: 10px;*/} +#map_building_inner ul {list-style-type:none;padding-left:0;margin:0;} +#map_building_inner li {margin:0px 0 4px 0;} +#map_building_inner ul li {padding-left:24px;line-height: 1.15em;} +#map_building_inner ul li {background:transparent url(img/dash-list.gif) no-repeat 5px 2px;} +#map_building_inner ul li li {background:transparent url(img/dash-list.gif) no-repeat 5px 1px;} + + +#map_building_permalink {margin:12px 16px 0 0px;text-align:left;font-size: 1.2em;} +#map_building_photo img{float:right;} + +#map_info_inner {margin:0 12px 0 0;padding:0 6px 6px 0;height: 156px;display: block;overflow: auto;overflow-x: hidden;/*(hide horizontal scroll bar)position: absolute;top: 140px;right: 10px;*/} + +#map_info_inner bd {font-size:1.0em;line-height:1.2em;} +#map_info_inner ul {list-style-type:none;padding-left:0;margin:0;} +#map_info_inner li {margin:0px 0 4px 0;} +#map_info_inner ul li {padding-left:24px;line-height: 1.15em;} +#map_info_inner ul li {background:transparent url(img/dash-list.gif) no-repeat 5px 2px;} +#map_info_inner ul li li {background:transparent url(img/dash-list.gif) no-repeat 5px 1px;} + +#map_entrancetab {font-size: 0.9em;width: 230px;} +#map_entrancetab img {padding:0;} +#map_entrancetab h4 {font-size: 1.2em;font-weight: bold;font-family: Arial, Helvetica, sans-serif;background-color: #29a7c2;color: #FFFFFF;margin:0 0 0 0;padding:0 3px 1px 3px;} +#map_entrancetab h4 a {display:block;color:#fff;} +#map_entrancetab_inner {margin:0 12px 0 0;padding:0 6px 6px 0;height: 60px;display: block;overflow: auto;overflow-x: hidden;/*(hide horizontal scroll bar)position: absolute;top: 140px;right: 10px;*/} +#map_entrancetab_inner bd {font-size:1.0em;line-height:1.2em;} +#map_entrancetab_inner ul {list-style-type:none;padding-left:0;margin:0;} +#map_entrancetab_inner li {margin:0px 0 4px 0;} +#map_entrancetab_inner ul li {padding-left:24px;line-height: 1.15em;} +#map_entrancetab_inner ul li {background:transparent url(img/dash-list.gif) no-repeat 5px 2px;} +#map_entrancetab_inner ul li li {background:transparent url(img/dash-list.gif) no-repeat 5px 1px;} + +#map_building_opening_hours, +#map_building_access {margin-bottom:6px;} + +#map_building_opening_hours p {margin:0 0 6px 0;} +#map_building_opening_hours strong {display:block;font-weight:normal;} + +#map_building_in_this {margin-bottom:6px;} +#map_building_in_this p {margin:0 0 6px 0;} +#map_building_in_this strong {display:block;font-weight:normal;} + + + + +#mapicons #Parking{width:10.25em;} +#mapicons #Entrances{width:7.25em;} +#mapicons #Loops{width:11em;} +#mapicons #Enabled_toilets{width:9.75em;} +#mapicons #Ramps{width:12.5em} + +#mapicons #Parking a{background:url(img/icon_accessible_parking.png) no-repeat 5px 3px;padding-left:26px;} +#mapicons #Entrances a{background:url(img/icon_entrance.png) no-repeat 5px 3px;padding-left:26px;} +#mapicons #Loops a{background:url(img/icon_loop.png) no-repeat 5px 3px;padding-left:26px;} +#mapicons #Enabled_toilets a{background:url(img/icon_accessible_toilet.png) no-repeat 5px 3px;padding-left:26px;} +#mapicons #Ramps a{background:url(img/icon_ramp.png) no-repeat 5px 3px;padding-left:26px;} + +#map_toilettab {font-size: 0.9em;width: 230px;} +#map_toilettab img {padding:0;} +#map_toilettab h4 {font-size: 1.2em;text-transform: uppercase;font-weight: bold;font-family: Arial, Helvetica, sans-serif;background-color: #29a7c2;color: #FFFFFF;margin:0 16px 0 0;padding:0 3px 1px 3px;} +#map_toilettab h4 a {display:block;color:#fff;} +#map_toilettab_inner {margin:0 12px 0 0;padding:0 6px 6px 0;height: 60px;display: block;overflow: auto;overflow-x: hidden;/*(hide horizontal scroll bar)position: absolute;top: 140px;right: 10px;*/} +#map_toilettab_inner bd {font-size:1.0em;line-height:1.2em;} +#map_toilettab_inner ul {list-style-type:none;padding-left:0;margin:0;} +#map_toilettab_inner li {margin:0px 0 4px 0;} +#map_toilettab_inner ul li {padding-left:24px;line-height: 1.15em;} +#map_toilettab_inner ul li {background:transparent url(img/dash-list.gif) no-repeat 5px 2px;} +#map_toilettab_inner ul li li {background:transparent url(img/dash-list.gif) no-repeat 5px 1px;} + +#parking-msg {font-size: 1.5em;font-weight: bold;font-family: Arial, Helvetica, sans-serif;color: #FFFFFF;margin:40px 40px 40px 40px;padding:0 3px 1px 3px;} diff --git a/tableKML.php b/tableKML.php new file mode 100644 index 0000000..d0daaae --- /dev/null +++ b/tableKML.php @@ -0,0 +1,32 @@ +\n"; +echo "\n"; + +$n=mysql_numrows($result); +$i=0; +while ($i < $n) { + $T=mysql_fetch_array($result, MYSQL_ASSOC); + echo "\n"; + echo "".$T[name]."\n"; + echo "\n"; + echo "".$T[lat].",".$T[lng].",0\n"; + echo "\n"; + echo "\n"; + $i+=1; +} +mysql_close(); + +echo "\n"; +?> -- cgit v1.2.3