Skip to content

Commit fb51afd

Browse files
committed
Map: Add API key for Yandex Maps
1 parent 665f6a4 commit fb51afd

File tree

3 files changed

+4
-1
lines changed

3 files changed

+4
-1
lines changed

config.php-distr

+2
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,8 @@ define('DEFAULT_LAT', 55.76);
4646
define('DEFAULT_LON', 37.64);
4747
define('DEFAULT_RAD', 2);
4848

49+
define('YMAPS_APIKEY', '');
50+
4951
// Users
5052
define('LOGIN_MIN', 5);
5153
define('LOGIN_MAX', 30);

index.php

+1
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,7 @@ function preparePage(&$content)
8585
$content = str_replace('%var_lat%', $lat, $content);
8686
$content = str_replace('%var_lon%', $lon, $content);
8787
$content = str_replace('%var_rad%', $rad, $content);
88+
$content = str_replace('%var_ymaps_apikey%', YMAPS_APIKEY, $content);
8889
$content = str_replace('%var_wait%', GUEST_WAIT, $content);
8990

9091
foreach ($l10n as $key => $value)

map.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<title>%l10n_title_map%</title>
22

33
<head>
4-
<script src="//api-maps.yandex.ru/2.1.55/?lang=ru-RU" type="text/javascript"></script>
4+
<script src="//api-maps.yandex.ru/2.1.74/?apikey=%var_ymaps_apikey%&lang=ru-RU" type="text/javascript"></script>
55
<script src="js/FileSaver.min.js" type="text/javascript"></script>
66
<script type="text/javascript">
77
function initmap()

0 commit comments

Comments
 (0)