Commit f7f73c853ece60629d83519f6f2d273e6021c9cc
1 parent
dc2827bb
plugin update
Showing
2 changed files
with
7 additions
and
4 deletions
datalets/base-datalet/base-datalet.html
@@ -362,7 +362,7 @@ Example : | @@ -362,7 +362,7 @@ Example : | ||
362 | success: function(data){ | 362 | success: function(data){ |
363 | if(data.status == "ok") | 363 | if(data.status == "ok") |
364 | { | 364 | { |
365 | - alert("Datalet added to private room"); | 365 | + alert("Datalet added to Myspace"); |
366 | } | 366 | } |
367 | else | 367 | else |
368 | { | 368 | { |
datalets/leafletjs-datalet/leafletjs-datalet.html
@@ -105,10 +105,13 @@ Example: | @@ -105,10 +105,13 @@ Example: | ||
105 | var popupText = ""; | 105 | var popupText = ""; |
106 | for(var j=2; j<t.data.length; j++) | 106 | for(var j=2; j<t.data.length; j++) |
107 | { | 107 | { |
108 | - if(t.data[j].data[i].toString().match(new RegExp("^(http[s]?:\\/\\/(www\\.)?|ftp:\\/\\/(www\\.)?|www\\.){1}([0-9A-Za-z-\\.@:%_\+~#=]+)+((\\.[a-zA-Z]{2,3})+)(/(.)*)?(\\?(.)*)?"))) | 108 | + if(typeof t.data[j] != 'undefined' && typeof t.data[j].data[i] != 'undefined') |
109 | + { | ||
110 | + if (t.data[j].data[i].toString().match(new RegExp("^(http[s]?:\\/\\/(www\\.)?|ftp:\\/\\/(www\\.)?|www\\.){1}([0-9A-Za-z-\\.@:%_\+~#=]+)+((\\.[a-zA-Z]{2,3})+)(/(.)*)?(\\?(.)*)?"))) | ||
109 | popupText += '<image height="100" width="100" src="' + t.data[j].data[i] + '" /><br/>'; | 111 | popupText += '<image height="100" width="100" src="' + t.data[j].data[i] + '" /><br/>'; |
110 | - else | ||
111 | - popupText += '<span>' + t.data[j].data[i] + '</span><br/>' | 112 | + else |
113 | + popupText += '<span>' + t.data[j].name + ' : ' + t.data[j].data[i] + '</span><br/>' | ||
114 | + } | ||
112 | } | 115 | } |
113 | 116 | ||
114 | var popup = L.popup().setContent(popupText); | 117 | var popup = L.popup().setContent(popupText); |