cvs: pearweb /public_html/javascript peardev_map.js

From: Date: Sat, 13 Jan 2007 21:06:23 +0000
Subject: cvs: pearweb /public_html/javascript peardev_map.js
Groups: php.pear.cvs php.pear.core 
Request: Send a blank email to pear-core+get-5350@lists.php.net to get a copy of this message
davidc Sat Jan 13 21:06:23 2007 UTC Modified files: /pearweb/public_html/javascript peardev_map.js Log: - Added Hidden email instead of undefined, added a a href on the maps as well and a mailto link to the mails when they are present http://cvs.php.net/viewvc.cgi/pearweb/public_html/javascript/peardev_map.js?r1=1.3&r2=1.4&diff_format=u Index: pearweb/public_html/javascript/peardev_map.js diff -u pearweb/public_html/javascript/peardev_map.js:1.3 pearweb/public_html/javascript/peardev_map.js:1.4 --- pearweb/public_html/javascript/peardev_map.js:1.3 Tue Dec 12 21:19:39 2006 +++ pearweb/public_html/javascript/peardev_map.js Sat Jan 13 21:06:23 2007 @@ -1,3 +1,12 @@ +/** + * This file is used to display the markers above + * the developers icons on the javascript map. + * + * @package pearweb + * @author David Coallier <davidc@php.net> + * @version CVS: $Id: peardev_map.js,v 1.4 2007/01/13 21:06:23 davidc Exp $ + */ + var map = document.getElementById('peardev_map'); if (map) { @@ -82,9 +91,19 @@ /** * The html in the marker */ - var peardevdesc = "User: " + points[i][2] + "<br />"; - peardevdesc += "Page: " + points[i][3] + "<br />"; - peardevdesc += "Email: " + points[i][4] + "<br />"; + var email = ''; + var username = points[i][2]; + var page = points[i][3]; + + if (!points[i][4]) { + email = 'Hidden Email'; + } else { + email = '<a href="mailto: ' + points[i][4] + '">points[i][4]</a>'; + } + + var peardevdesc = "User: " + username + "<br />"; + peardevdesc += "Page: <a href='" + page + "'>" + page + "</a><br />"; + peardevdesc += "Email: " + email + "<br />"; var newpoint = new GLatLng(points[i][0], points[i][1]); gmapped.addOverlay(createMarker(newpoint, peardevdesc));

« previous php.pear.core (#5350) next »